Re: bindkey: How to map Alt key (2022-07-28 02:50 by maxgyver83 #90681)
> But actually I would like to bind it to Alt-v. How can I achieve this? I have tried so far:
>
> bindkey --emacs '\^[V' vi-edit-and-accept
> bindkey --emacs '^[V' vi-edit-and-accept
> bindkey --emacs '^[v' vi-edit-and-accept
> bindkey --emacs '\^\[V' vi-edit-and-accept
Sorry for bothering you. After thinking again, I found it:
bindkey --emacs '\^[v' vi-edit-and-accept
I think the rule of thumb is: Use backslash plus what you get when you type Ctrl-v and then the key combo you want to use.
(It seems to be the same in bash: For key combos with Ctrl you use capital letters, for key combos with Alt you use minor letters.)