Revert part of 77946 and 77978 so things work against when EDITOR is set to

something with spaces in it.

BUG=none
TEST=none
Review URL: http://codereview.chromium.org/6686046

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@78027 0039d316-1c4b-4281-b951-d872f2087c98
experimental/szager/collated-output
thomasvl@chromium.org 15 years ago
parent 602e0a7e88
commit ca7953a5e8

@ -1064,13 +1064,10 @@ def CMDchange(args):
os.close(handle)
# Open up the default editor in the system to get the CL description.
cmd = [GetEditor(), filename]
if sys.platform == 'win32' and os.environ.get('TERM') == 'msys':
# Msysgit requires the usage of 'env' to be present.
cmd.insert(0, 'env')
result = None
try:
if not silent:
subprocess.check_call(cmd)
os.system(GetEditor() + " " + filename)
result = gclient_utils.FileRead(filename, 'r')
finally:
os.remove(filename)

@ -711,12 +711,9 @@ def UserEditedLog(starting_text):
fileobj.close()
# Open up the default editor in the system to get the CL description.
cmd = [editor, filename]
if sys.platform == 'win32' and os.environ.get('TERM') == 'msys':
# Msysgit requires the usage of 'env' to be present.
cmd.insert(0, 'env')
result = None
try:
subprocess.check_call(cmd)
subprocess.check_call(['env', editor, filename], shell=True)
fileobj = open(filename)
result = fileobj.read()
fileobj.close()

Loading…
Cancel
Save