-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
the documented solution for hybrid key bindings does not work #3556
Comments
Another side-effect of the simple solution I proposed above is that |
I personally would see that as a bug. If I'm using vi mode, I would expect to see the vi mode indicator. May I ask what the rationale was for removing key bindings from vi mode? #3068 did not really explain its rationale at all, other than "it shared too much." It worked pretty well for me before 2.4 was released. |
In fact, we should package the
There has been talk about tying the vi mode indicator to something other than the value of |
I personally stopped using vi mode after 2.4.0 - but I think I was just very used to the old more-shared behavior. I'm not sure what's better. I'm not a vi power user. |
I stopped using vi mode many months ago because the inconsistencies with true Vi behavior was just too annoying. And I found that after creating a
PR forthcoming to implement a working hybrid mode. TBD is whether we want the current |
The main problem, @dead10ck, is that hybrid mode causes characters not otherwise bound in "default" (i.e., vi normal) mode to self-insert. Which means that after pressing [escape] to switch from insert to normal mode pressing |
Per the discussion in issue #3068 the emacs specific bindings are no longer automatically included in the vi mode bindings. Recognizing that some people would still want to be able to create a hybrid of the default (aka emacs) and vi bindings we documented how to do so:
Unfortunately that won't work. The reason is that the
fish_vi_key_bindings
function executesThat triggers the fish C++ code to run the function a second time without the
--no-erase
flag (or any arguments for that matter).The simplest solution is to also predicate that
set
on whether the function was not invoked with the--no-erase
flag. That fixes the problem. Albeit with the side-effect that because$fish_key_bindings
is no longerfish_vi_key_bindings
you won't see the vi mode indicator; e.g.,[I]
or[N]
. However, I suspect that most users of hybrid key bindings will view that as a feature.The text was updated successfully, but these errors were encountered: