Split EDITOR environment variable to handle flags in prefix.

This commit is contained in:
Jimmy Berry 2017-11-22 09:13:06 -06:00
parent b428ed3a7d
commit 664f3bbb90
2 changed files with 2 additions and 2 deletions

View File

@ -131,7 +131,7 @@ def prompt_interactive(changes, project, package):
editor = os.getenv('EDITOR')
if not editor:
editor = 'xdg-open'
subprocess.call([editor, temp.name])
subprocess.call(editor.split(' ') + [temp.name])
changes_after = yaml.safe_load(open(temp.name).read())
if changes_after is None:

View File

@ -599,7 +599,7 @@ def do_staging(self, subcmd, opts, *args):
editor = os.getenv('EDITOR')
if not editor:
editor = 'xdg-open'
return_code = subprocess.call([editor, temp.name])
return_code = subprocess.call(editor.split(' ') + [temp.name])
proposal = yaml.safe_load(open(temp.name).read())