mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-22 11:22:52 +08:00
Vi bindings: Control-N to accept autosuggestion
One of the things that keep me from using Vi mode is that it doesn't define an insert-mode shortcut to accept autosuggestions. Let's use Control-N because that Vim key is the closest equivalent. Closes #10339
This commit is contained in:
parent
b3c610feff
commit
836ee93617
|
@ -104,6 +104,8 @@ function fish_vi_key_bindings --description 'vi-like key bindings for fish'
|
|||
bind -s --preset e forward-single-char forward-word backward-char
|
||||
bind -s --preset E forward-single-char forward-bigword backward-char
|
||||
|
||||
bind -s --preset -M insert \cn accept-autosuggestion
|
||||
|
||||
# Vi/Vim doesn't support these keys in insert mode but that seems silly so we do so anyway.
|
||||
bind -s --preset -M insert -k home beginning-of-line
|
||||
bind -s --preset -M default -k home beginning-of-line
|
||||
|
|
Loading…
Reference in New Issue
Block a user