mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-12-26 02:12:33 +01:00
Theme kaffeefleck now compatible with miloshadzic
* Flag for the root prefix: ZSH_THEME_PREFIX_ROOT * Flag for the RPROMPT: ZSH_THEME_USE_RPROMPT
This commit is contained in:
parent
0989ae36cb
commit
b323d92d36
1 changed files with 5 additions and 3 deletions
|
|
@ -6,7 +6,7 @@ ZSH_THEME_GIT_PROMPT_CLEAN=""
|
|||
local directory="%{$fg[cyan]%}%1~%{$reset_color%}"
|
||||
local left_delimiter="%{$fg[red]%}|%{$reset_color%}"
|
||||
local right_delimiter=" %{$fg[cyan]%}⇒%{$reset_color%} "
|
||||
if [ $UID -eq 0 ]; then
|
||||
if [[ "$ZSH_THEME_PREFIX_ROOT" != "" && "$UID" -eq 0 ]]; then
|
||||
local root_prefix="%{$fg[red]%}♚ %{$reset_color%}"
|
||||
else
|
||||
local root_prefix=""
|
||||
|
|
@ -14,5 +14,7 @@ fi
|
|||
|
||||
PROMPT='${root_prefix}${directory}${left_delimiter}$(git_prompt_info)${right_delimiter}'
|
||||
|
||||
local return_code="%(?..%{$fg[red]%}%?%{$reset_color%})"
|
||||
RPROMPT='${return_code}'
|
||||
if [ "$ZSH_THEME_USE_RPROMPT" != "" ]; then
|
||||
local return_code="%(?..%{$fg[red]%}%?%{$reset_color%})"
|
||||
RPROMPT='${return_code}'
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue