eb308c57 | set -o vi |
8ba81c71 | bindkey -v # We want the up + down arrows to do completion autoload -U up-line-or-beginning-search autoload -U down-line-or-beginning-search zle -N up-line-or-beginning-search zle -N down-line-or-beginning-search |
3745c88f | bindkey -M vicmd '?' history-incremental-search-backward bindkey -M vicmd '/' history-incremental-search-forward |
8ba81c71 | bindkey -M viins "^[[A" up-line-or-beginning-search # Up bindkey -M vicmd "^[[A" up-line-or-beginning-search # Up bindkey -M viins "^[[B" down-line-or-beginning-search # Down bindkey -M vicmd "^[[B" down-line-or-beginning-search # Down |
3745c88f | |
8ba81c71 | bindkey -M vicmd "k" up-line-or-beginning-search # Up bindkey -M vicmd "j" down-line-or-beginning-search # Down |
eb308c57 | bindkey -M vicmd '?' history-incremental-search-backward |
8ba81c71 | bindkey -M viins '^X^e' edit-command-line |
3745c88f | bindkey -M vicmd '^X^e' edit-command-line |
8ba81c71 | bindkey -M viins '^I' complete-word |
eb308c57 | bindkey -M viins '^Oc' _correct_word bindkey -M viins '^O?' _complete_debug # detecting the terminal to get the keybindings right # TODO: check if obsoleted by other things if [[ -z $BINDKEYS ]]; then # echo 'defining bindkeys in zshrc' BINDKEYS=${TERM%-256color} BINDKEYS=${BINDKEYS%-noit} fi if [[ $BINDKEYS == "screen" ]]; then bindkey '[D' backward-word bindkey '[C' forward-word bindkey '[1~' beginning-of-line bindkey '[4~' end-of-line else bindkey -M viins '[1;5D' backward-word # bindkey '[5D' backward-word bindkey -M viins '[1;5C' forward-word # bindkey '[5C' forward-word bindkey -M viins 'OH' beginning-of-line bindkey -M viins 'OF' end-of-line fi bindkey '[3~' delete-char |
3745c88f | export KEYTIMEOUT=1 |