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

Re: bindkey and vi mode question



[ Quoting Miek Gieben in "Re: bindkey and vi mode question"... ]
> This works:
> bindkey "^p" history-beginning-search-backward-end
> bindkey "^n" history-beginning-search-forward-end
> 
> These not: (arrow-up/down)
> bindkey "^[[A" history-beginning-search-backward-end
> bindkey "^[[B" history-beginning-search-forward-end
> 
> It seems that AFTER all my own zsh files are parsed,
> my (viins) keymap is somehow reset (at least for arraw-up/down)
> 
> Very strange...

This in on Ubuntu. I can get it working if a disable
/etc/zsh/zshrc, which has the following lines:

% grep history zshrc        
[[ -z "$terminfo[cuu1]" ]] || bindkey -M viins "$terminfo[cuu1]" vi-up-line-or-history
[[ -z "$terminfo[kcuu1]" ]] || bindkey -M viins "$terminfo[kcuu1]" vi-up-line-or-history
[[ -z "$terminfo[kcud1]" ]] || bindkey -M viins "$terminfo[kcud1]" vi-down-line-or-history
[[ "$terminfo[kcuu1]" == "â ]] && bindkey -M viins "${terminfo[kcuu1]/O/[}" vi-up-line-or-history
[[ "$terminfo[kcud1]" == "â ]] && bindkey -M viins "${terminfo[kcud1]/O/[}" vi-down-line-or-history

Well at least I know what to do :) But still very strange as I thought
these system startup files are sources BEFORE mine are...

Regards, Miek

Attachment: signature.asc
Description: Digital signature



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