diff options
author | Patrick Totzke <patricktotzke@gmail.com> | 2012-06-26 20:06:12 +0100 |
---|---|---|
committer | Patrick Totzke <patricktotzke@gmail.com> | 2012-06-26 20:06:12 +0100 |
commit | 1e66018acc312c9bec6c21ce25cd5cac91f6762d (patch) | |
tree | eeaddb9505bc71b1765a93bfe850b2bf83e452b1 | |
parent | df1d735350ff3f07c2df35b62b8362c1142ac03d (diff) | |
parent | 2a7d1fd2dcc7354b06faa0da5574324b3578eba1 (diff) |
Merge branch '0.3.1-fix-X11less-edit-460'
-rw-r--r-- | alot/commands/globals.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/alot/commands/globals.py b/alot/commands/globals.py index 88a2e8fc..dcf0c7a5 100644 --- a/alot/commands/globals.py +++ b/alot/commands/globals.py @@ -174,11 +174,14 @@ class ExternalCommand(Command): logging.debug('got: %s' % res) cmd, shell, self.in_thread = res # otherwise if spawn requested and X11 is running - elif spawn and 'DISPLAY' in os.environ: - term_cmd = settings.get('terminal_cmd', '') - logging.info('spawn in terminal: %s' % term_cmd) - termcmdlist = split_commandstring(term_cmd) - cmd = termcmdlist + cmd + elif spawn: + if 'DISPLAY' in os.environ: + term_cmd = settings.get('terminal_cmd', '') + logging.info('spawn in terminal: %s' % term_cmd) + termcmdlist = split_commandstring(term_cmd) + cmd = termcmdlist + cmd + else: + thread = False self.cmdlist = cmd self.stdin = stdin |