diff options
author | johannst <stoelp@eit.uni-kl.de> | 2019-05-18 16:12:54 +0200 |
---|---|---|
committer | johannst <stoelp@eit.uni-kl.de> | 2019-05-18 16:12:54 +0200 |
commit | bc5daef75f0521dbe1e6456c5e87a9719bc553cf (patch) | |
tree | faebf36c83b947e60ea7fb06aaee9a0b3538d351 | |
parent | 973de4fa7527c13f757b526a05920d4d0793e834 (diff) | |
download | dotfiles-bc5daef75f0521dbe1e6456c5e87a9719bc553cf.tar.gz dotfiles-bc5daef75f0521dbe1e6456c5e87a9719bc553cf.zip |
Added base16 version of my prompt
-rw-r--r-- | zshrc | 29 |
1 files changed, 29 insertions, 0 deletions
@@ -103,6 +103,13 @@ color[pinkRed]='%F{125}' color[babyBlue]='%F{38}' color[darkBlue]='%F{26}' +function printBase16() { + for i in $(seq 0 15); do + str="" + print -P "%F{$i} Color $i %f"; + done +} + function _installMyPrompt() { function zle-line-init zle-keymap-select { vinorm='n' @@ -117,6 +124,28 @@ function _installMyPrompt() { zle -N zle-keymap-select } +function _installMyPromptBase16() { + function zle-line-init zle-keymap-select { + vinorm='n' + viins='i' + c_del='%F{7}' + c_usr='%F{6}' + c_hos='%F{5}' + c_tty='%F{8}' + c_ret='%F{1}' + c_vii='%F{14}' + c_vic='%F{16}' + vimode="${${KEYMAP/vicmd/$c_vic$vinorm}/(main|viins)/$c_vii$viins}%f" + PS1="$c_usr%n$c_del::$c_hos%m$c_del:$c_tty%l%f [$vimode] $c_ret%(?..%? )$c_del%f> " + RPS1="%F{4}%~%f" + zle reset-prompt + } + + zle -N zle-line-init + zle -N zle-keymap-select +} + _installMyPrompt +#_installMyPromptBase16 #% vim:et:fen:fdm=marker:fmr={{{,}}}:fdl=0:fdc=1 |