From d5a94dda74fdd0b6fe50f7567794e8ccff589465 Mon Sep 17 00:00:00 2001 From: Sorin Ionescu Date: Mon, 2 Apr 2012 23:43:32 -0400 Subject: [PATCH] [#23] Rename keymap indicator zstyles --- modules/editor/init.zsh | 8 ++++---- modules/prompt/functions/prompt_sorin_setup | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/modules/editor/init.zsh b/modules/editor/init.zsh index 93d4fef8..432ce118 100644 --- a/modules/editor/init.zsh +++ b/modules/editor/init.zsh @@ -13,10 +13,10 @@ fi # The default styles. # Indicator to notify of vi insert mode. -zstyle ':omz:prompt:vi' insert '>>>' +zstyle ':omz:module:editor:keymap' primary '>>>' # Indicator to notify of vi command mode. -zstyle ':omz:prompt:vi' command '<<<' +zstyle ':omz:module:editor:keymap' alternate '<<<' # Indicator to notify of generating completion. zstyle ':omz:module:editor' completing '...' @@ -72,9 +72,9 @@ done # Displays the current vi mode. function zle-line-init zle-line-finish zle-keymap-select { if [[ "$KEYMAP" == 'vicmd' ]]; then - zstyle -s ':omz:prompt:vi' command 'vi_prompt_info' + zstyle -s ':omz:module:editor:keymap' alternate 'editor_keymap_info' else - zstyle -s ':omz:prompt:vi' insert 'vi_prompt_info' + zstyle -s ':omz:module:editor:keymap' primary 'editor_keymap_info' fi zle reset-prompt zle -R diff --git a/modules/prompt/functions/prompt_sorin_setup b/modules/prompt/functions/prompt_sorin_setup index 1bc2cef2..fc199501 100644 --- a/modules/prompt/functions/prompt_sorin_setup +++ b/modules/prompt/functions/prompt_sorin_setup @@ -26,8 +26,8 @@ function prompt_sorin_setup { add-zsh-hook precmd prompt_sorin_precmd zstyle ':omz:module:editor' completing '%B%F{red}...%f%b' - zstyle ':omz:prompt:vi' insert '' - zstyle ':omz:prompt:vi' command ' %F{yellow}❮%f%B%F{red}❮%f%b%F{red}❮%f' + zstyle ':omz:module:editor:keymap' primary '' + zstyle ':omz:module:editor:keymap' alternate ' %F{yellow}❮%f%B%F{red}❮%f%b%F{red}❮%f' zstyle ':omz:module:git:prompt' action ':%%B%F{yellow}%s%f%%b' zstyle ':omz:module:git:prompt' added ' %%B%F{green}✚%f%%b' zstyle ':omz:module:git:prompt' ahead ' %%B%F{yellow}⬆%f%%b' @@ -45,7 +45,7 @@ function prompt_sorin_setup { zstyle ':omz:module:git:prompt' rprompt '%A%B%S%a%d%m%r%U%u' PROMPT='%F{cyan}%1~%f${(e)git_prompt_info} %(!.%B%F{red}#%f%b.%B%F{green}❯%f%b) ' - RPROMPT='${vi_prompt_info}%(?:: %F{red}⏎%f)${VIM:+" %B%F{green}V%f%b"}${git_rprompt_info}' + RPROMPT='${editor_keymap_info}%(?:: %F{red}⏎%f)${VIM:+" %B%F{green}V%f%b"}${git_rprompt_info}' SPROMPT='zsh: correct %F{red}%R%f to %F{green}%r%f [nyae]? ' }