key_bindings: map escape-right as another word completer for macOS (#5056) (#5059)

This commit is contained in:
doronz88 2023-02-15 18:31:21 +02:00 committed by GitHub
parent 23c2f2034d
commit 204bb99079
Failed to generate hash of commit
2 changed files with 27 additions and 0 deletions

23
news/5056.rst Normal file
View file

@ -0,0 +1,23 @@
**Added:**
* key_bindings: map `escape-f` as another word completer for macOS
**Changed:**
* <news item>
**Deprecated:**
* <news item>
**Removed:**
* <news item>
**Fixed:**
* <news item>
**Security:**
* <news item>

View file

@ -429,4 +429,8 @@ def load_xonsh_bindings(ptk_bindings: KeyBindingsBase) -> KeyBindingsBase:
# Complete a single auto-suggestion word
create_alias([Keys.ControlRight], ["escape", "f"])
# since macOS uses Control as reserved, then we use the alt/option key instead
# which is mapped as the "escape" key
create_alias(["escape", "right"], ["escape", "f"])
return key_bindings