Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Some zsh questions

On 1 Dec, "A. Wik" wrote:
> (1) when I use ^X^V to enter vi command mode, then go to insert mode,
> I can't get back to command mode using ESC, but using ^X^V again
> works.  It's in the keymap:
> % bindkey -M viins |grep -i cmd
> "^[" vi-cmd-mode
> Incidentally, for some reason ^X^V is not listed.

You're probably using emacs mode for the insert mode:
% bindkey -M emacs|grep -i cmd
"^X^V" vi-cmd-mode

Entering something like a or i from the vicmd keymap doesn't
specifically set the keymap to viins. You go back to whatever the main
keymap is aliased to. Run bindkey -lL to see.
If you want a hybrid of emacs and vi mode, you can always do:
  bindkey -M emacs '^[' vi-cmd-mode

> (3) Copying and pasting acts weird when I use zsh but not bash; eg:
> % echo $SHELL
> /bin/zsh
> % 0~echo $SHELL1~ 0~/bin/zsh1~

It looks like the bracketed paste sequences that the terminal generates
before and after pasted text are not being handled. These are handled as
a normal key binding:
  % bindkey -L|grep brack
  bindkey "^[[200~" bracketed-paste

Are you perhaps clearing all bindings or loading an alternative paste


Messages sorted by: Reverse Date, Date, Thread, Author