aboutsummaryrefslogtreecommitdiff
path: root/dotfiles/.config/zsh/.zshrc
diff options
context:
space:
mode:
authorYaroslav de la Peña Smirnov <yps@yaroslavps.com>2021-09-30 20:56:04 +0300
committerYaroslav de la Peña Smirnov <yps@yaroslavps.com>2021-09-30 20:56:04 +0300
commit3f6bb9f7ddc34fdd9af3d8ae3b0c00b882027843 (patch)
treee26cb65d778e576aa441d4f4a6b680bf6b0d3b14 /dotfiles/.config/zsh/.zshrc
parentf2aa61e910a8ccab62579a82fdc3e756cd1bd960 (diff)
downloadswayrice-3f6bb9f7ddc34fdd9af3d8ae3b0c00b882027843.tar.gz
swayrice-3f6bb9f7ddc34fdd9af3d8ae3b0c00b882027843.zip
zsh: history search bindings
Diffstat (limited to 'dotfiles/.config/zsh/.zshrc')
-rw-r--r--dotfiles/.config/zsh/.zshrc6
1 files changed, 6 insertions, 0 deletions
diff --git a/dotfiles/.config/zsh/.zshrc b/dotfiles/.config/zsh/.zshrc
index 727bfe0..a744585 100644
--- a/dotfiles/.config/zsh/.zshrc
+++ b/dotfiles/.config/zsh/.zshrc
@@ -38,6 +38,12 @@ bindkey -M menuselect 'L' vi-forward-char
bindkey -M menuselect 'J' vi-down-line-or-history
bindkey -v '^?' backward-delete-char
+# History search
+bindkey "^[[A" history-search-backward
+bindkey "^[[B" history-search-forward
+bindkey -a "k" history-search-backward
+bindkey -a "j" history-search-forward
+
# Change cursor shape for different vi modes.
function zle-keymap-select {
if [[ ${KEYMAP} == vicmd ]] ||