Really allow for hybrid bindings

The previous solution would not erase the previous bindings if
fish_vi_key_bindings was called with a mode argument. So if the user
switched to vi with a different initial mode, they'd keep their previous
bindings also.

Supersedes e89057b.
This commit is contained in:
Fabian Homborg
2016-09-05 00:47:37 +02:00
parent 30f26b62e6
commit 7ce042ccff
2 changed files with 25 additions and 16 deletions

View File

@@ -960,7 +960,7 @@ function hybrid_bindings --description "Vi-style bindings that inherit emacs-sty
for mode in default insert visual
fish_default_key_bindings -M $mode
end
fish_vi_key_bindings
fish_vi_key_bindings --no-erase
end
set -g fish_key_bindings hybrid_bindings
\endfish