From 856ac772334d5f9a6fef4ca27ff5ac22275750ee Mon Sep 17 00:00:00 2001 From: Gregor Bollerhey Date: Sat, 11 Jan 2014 06:14:02 +0100 Subject: [PATCH] First cd, then execute [terminal] command. --- src/xdgmenumaker | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/xdgmenumaker b/src/xdgmenumaker index 47f1847..089c32e 100755 --- a/src/xdgmenumaker +++ b/src/xdgmenumaker @@ -158,13 +158,13 @@ def get_entry_info(desktopfile): # removing any %U or %F from the exec line command = de.getExec().partition('%')[0] - depath = de.getPath() - if depath: - command = 'cd %s && %s' % (depath, command) - use_terminal = de.getTerminal() if use_terminal is True: command = '%s -e %s' % (terminal, command) + + depath = de.getPath() + if depath: + command = 'cd %s && %s' % (depath, command) # cleaning up categories and keeping only registered freedesktop.org main categories categories = de.getCategories()