diff options
author | shmibs <shmibs@gmail.com> | 2015-08-11 07:54:54 -0700 |
---|---|---|
committer | shmibs <shmibs@gmail.com> | 2015-08-11 07:54:54 -0700 |
commit | d81387638bc304c0a91e30b6cb8eb524efc9bf2d (patch) | |
tree | a950eea9e82d8b3ed58f3ad0862060460d89c789 | |
parent | 74495ab4c2aff7dc618b021990ce098dafbd22ad (diff) | |
download | dotfiles-d81387638bc304c0a91e30b6cb8eb524efc9bf2d.tar.gz |
multi-line prompt with extra context
-rw-r--r-- | .zshrc | 16 |
1 files changed, 15 insertions, 1 deletions
@@ -20,7 +20,21 @@ bindkey -e setopt notify unsetopt beep -PROMPT="%{%B$fg[white]%}[%{%(!.$fg[red].$fg[magenta])%}%n@%M %{$fg[blue]%}%c%{$fg[white]%}]: %{%b$reset_color%}" +#################### PROMPT ################### +PROMPT="%{%B$fg[white]%}┌[" +# if non-zero, previous return val +PROMPT+="%(0?..$fg[red]%?$fg[white]:)" +# if any, number of jobs +PROMPT+="%(1j.$fg[green]%j$fg[white]:.)" +# name and host (red for root) +PROMPT+="%{%(!.$fg[red].$fg[magenta])%}%n@%M%E " +# current location, with one level of parent context +PROMPT+="%{$fg[blue]%}%2c" +# newline +PROMPT+="%{$fg[white]%}]%{%b$reset_color%} +" +PROMPT+="%{%B$fg[white]%}└: %{%b$reset_color%}" + ################# HIGHLIGHTING ################ if [[ -f '/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh' ]]; then |