mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-28 22:03:12 +00:00
bindings: expand abbreviations with all end-of-command characters
Closes #6970.
This commit is contained in:
parent
ad020e84dd
commit
ec74c739c8
1 changed files with 8 additions and 1 deletions
|
@ -31,8 +31,15 @@ function fish_default_key_bindings -d "Default (Emacs-like) key bindings for fis
|
|||
bind --preset $argv "" self-insert
|
||||
or exit # protect against invalid $argv
|
||||
|
||||
# Space expands abbrs _and_ inserts itself.
|
||||
# Space and other command terminators expands abbrs _and_ inserts itself.
|
||||
bind --preset $argv " " self-insert expand-abbr
|
||||
bind --preset $argv ";" self-insert expand-abbr
|
||||
bind --preset $argv "|" self-insert expand-abbr
|
||||
bind --preset $argv "&" self-insert expand-abbr
|
||||
bind --preset $argv "^" self-insert expand-abbr
|
||||
bind --preset $argv ">" self-insert expand-abbr
|
||||
bind --preset $argv "<" self-insert expand-abbr
|
||||
# Closing a command substitution expands abbreviations
|
||||
bind --preset $argv ")" self-insert expand-abbr
|
||||
# Ctrl-space inserts space without expanding abbrs
|
||||
bind -k nul 'commandline -i " "'
|
||||
|
|
Loading…
Reference in a new issue