diff options
author | toonn <toonn@toonn.io> | 2019-10-01 23:18:00 +0200 |
---|---|---|
committer | toonn <toonn@toonn.io> | 2019-10-02 01:43:04 +0200 |
commit | 3417dc99a39f860b2a91fcc43e165c7b1707fb7a (patch) | |
tree | 9d4747976116bc7d6958ab99724d774f142fcff2 | |
parent | 11087fd48f4fcbec9112a25d77eec0a5b2211d9f (diff) | |
download | ranger-3417dc99a39f860b2a91fcc43e165c7b1707fb7a.tar.gz |
Don't resolve macros for chain
Macros are resolved for subcommands and the double resolution leads to having to escape macros, which is bad UX. This does only show up in select cases, such as with `%%space` at the end of a chained command. Fixes #1640
-rwxr-xr-x | ranger/config/commands.py | 1 | ||||
-rw-r--r-- | ranger/config/rc.conf | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/ranger/config/commands.py b/ranger/config/commands.py index 55dd9cd1..b7f48eb2 100755 --- a/ranger/config/commands.py +++ b/ranger/config/commands.py @@ -282,6 +282,7 @@ class chain(Command): Calls multiple commands at once, separated by semicolons. """ + resolve_macros = False def execute(self): if not self.rest(1).strip(): diff --git a/ranger/config/rc.conf b/ranger/config/rc.conf index 00a20def..2ca32e3c 100644 --- a/ranger/config/rc.conf +++ b/ranger/config/rc.conf @@ -366,7 +366,7 @@ map ! console shell%space map @ console -p6 shell %%s map # console shell -p%space map s console shell%space -map r chain draw_possible_programs; console open_with%%space +map r chain draw_possible_programs; console open_with%space map f console find%space map cd console cd%space |