diff options
-rw-r--r-- | README.md | 6 | ||||
-rwxr-xr-x | powerlevel9k.zsh-theme | 6 |
2 files changed, 10 insertions, 2 deletions
@@ -231,6 +231,12 @@ VI-Mode, you need to configure it separately in your `~/.zshrc`: # make it more responsive export KEYTIMEOUT=1 +If you want to display another string than "NORMAL" or "INSERT" in command or +insert-mode, you can do that by setting environment variables like: + + POWERLEVEL9K_VI_INSERT_MODE_STRING="INS" + POWERLEVEL9K_VI_COMMAND_MODE_STRING="CMD" + #### Unit Test Ratios The `symfony2_tests` and `rspec_stats` segments both show a ratio of "real" diff --git a/powerlevel9k.zsh-theme b/powerlevel9k.zsh-theme index c2ee2625..0af9f56d 100755 --- a/powerlevel9k.zsh-theme +++ b/powerlevel9k.zsh-theme @@ -850,13 +850,15 @@ prompt_time() { } # Vi Mode: show editing mode (NORMAL|INSERT) +set_default POWERLEVEL9K_VI_INSERT_MODE_STRING "INSERT" +set_default POWERLEVEL9K_VI_COMMAND_MODE_STRING "NORMAL" prompt_vi_mode() { case ${KEYMAP} in main|viins) - "$1_prompt_segment" "$0_INSERT" "$DEFAULT_COLOR" "blue" "INSERT" + "$1_prompt_segment" "$0_INSERT" "$DEFAULT_COLOR" "blue" "$POWERLEVEL9K_VI_INSERT_MODE_STRING" ;; vicmd) - "$1_prompt_segment" "$0_NORMAL" "$DEFAULT_COLOR" "default" "NORMAL" + "$1_prompt_segment" "$0_NORMAL" "$DEFAULT_COLOR" "default" "$POWERLEVEL9K_VI_COMMAND_MODE_STRING" ;; esac } |