removed vi-mode keybindings in favor of vi-mode plugin

This commit is contained in:
2019-03-18 15:25:22 -04:00
parent 0b43f26f8f
commit b766df440a

18
.zshrc
View File

@@ -9,7 +9,6 @@ export ZSH=$HOME/.oh-my-zsh
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes # See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
# ZSH_THEME="robbyrussell" # ZSH_THEME="robbyrussell"
# ZSH_THEME="avit" # ZSH_THEME="avit"
ZSH_THEME="bureau" ZSH_THEME="bureau"
# Uncomment the following line to use case-sensitive completion. # Uncomment the following line to use case-sensitive completion.
@@ -54,7 +53,7 @@ COMPLETION_WAITING_DOTS="true"
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse) # Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup. # Add wisely, as too many plugins slow down shell startup.
plugins=(git zsh-autosuggestions zsh-completions) plugins=(git zsh-autosuggestions zsh-completions vi-mode)
# User configuration # User configuration
@@ -91,7 +90,6 @@ setopt share_history
# ==> KEY BINDINGS - from https://dougblack.io/words/zsh-vi-mode.html # ==> KEY BINDINGS - from https://dougblack.io/words/zsh-vi-mode.html
# #
# Vim Keybindings
bindkey -v bindkey -v
bindkey '^P' up-history bindkey '^P' up-history
bindkey '^N' down-history bindkey '^N' down-history
@@ -100,20 +98,6 @@ bindkey '^h' backward-delete-char
bindkey '^w' backward-kill-word bindkey '^w' backward-kill-word
bindkey '^r' history-incremental-search-backward bindkey '^r' history-incremental-search-backward
#function zle-line-init zle-keymap-select {
# VIM_PROMPT="%{$fg_bold[yellow]%} [% NORMAL]% %{$reset_color%}"
# RPS1="${${KEYMAP/vicmd/$VIM_PROMPT}/(main|viins)/}$(git_custom_status) $EPS1"
# zle reset-prompt
#}
function zle-line-init zle-keymap-select {
RPS1="${${KEYMAP/vicmd/-- NORMAL --}/(main|viins)/-- INSERT --}"
RPS2=$RPS1
zle reset-prompt
}
zle -N zle-line-init
zle -N zle-keymap-select
export KEYTIMEOUT=1 export KEYTIMEOUT=1