1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-11-23 14:20:08 +00:00

Changed text color to red when 'root'

This commit is contained in:
Vanildo Souto Mangueira 2018-08-30 14:49:25 -03:00
parent dc8811f817
commit 4a876ac7e2

View file

@ -34,8 +34,11 @@ ZSH_THEME_GIT_PROMPT_AHEAD=" %{$RED%}(!)"
ZSH_THEME_GIT_PROMPT_SHA_BEFORE=" %{$WHITE%}[%{$YELLOW%}" ZSH_THEME_GIT_PROMPT_SHA_BEFORE=" %{$WHITE%}[%{$YELLOW%}"
ZSH_THEME_GIT_PROMPT_SHA_AFTER="%{$WHITE%}]" ZSH_THEME_GIT_PROMPT_SHA_AFTER="%{$WHITE%}]"
USER_COLOR=$GREEN_BOLD
[[ $UID -eq 0 ]] && USER_COLOR=$RED_BOLD
# Prompt format # Prompt format
PROMPT=' PROMPT='
%{$GREEN_BOLD%}%n@%m%{$WHITE%}:%{$YELLOW%}%~%u$(parse_git_dirty)$(git_prompt_ahead)%{$RESET_COLOR%} %{$USER_COLOR%}%n@%m%{$WHITE%}:%{$YELLOW%}%~%u$(parse_git_dirty)$(git_prompt_ahead)%{$RESET_COLOR%}
%{$BLUE%}>%{$RESET_COLOR%} ' %{$BLUE%}>%{$RESET_COLOR%} '
RPROMPT='%{$GREEN_BOLD%}$(git_current_branch)$(git_prompt_short_sha)$(git_prompt_status)%{$RESET_COLOR%}' RPROMPT='%{$GREEN_BOLD%}$(git_current_branch)$(git_prompt_short_sha)$(git_prompt_status)%{$RESET_COLOR%}'