mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-04-03 04:20:01 +02:00
history-substring-search: bind arrows in both vi and emacs keymaps
This commit is contained in:
parent
b457ae2501
commit
e8678be701
1 changed files with 6 additions and 2 deletions
|
|
@ -15,9 +15,13 @@ fi
|
|||
# Bind terminal-specific up and down keys
|
||||
|
||||
if [[ -n "$terminfo[kcuu1]" ]]; then
|
||||
bindkey "$terminfo[kcuu1]" history-substring-search-up
|
||||
bindkey -M emacs "$terminfo[kcuu1]" history-substring-search-up
|
||||
bindkey -M viins "$terminfo[kcuu1]" history-substring-search-up
|
||||
bindkey -M vicmd "$terminfo[kcuu1]" history-substring-search-up
|
||||
fi
|
||||
if [[ -n "$terminfo[kcud1]" ]]; then
|
||||
bindkey "$terminfo[kcud1]" history-substring-search-down
|
||||
bindkey -M emacs "$terminfo[kcud1]" history-substring-search-down
|
||||
bindkey -M viins "$terminfo[kcud1]" history-substring-search-down
|
||||
bindkey -M vicmd "$terminfo[kcud1]" history-substring-search-down
|
||||
fi
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue