851899e59ea71ce8fbae738ec7aeb7a967585977

Author
Brian Hong <brian@hongs.me>
Committer
Marc Cornellà <marc.cornella@live.com>
Date

Message

theme/gallifrey: set color to red if root (#6203)

Diff

 1diff --git a/themes/gallifrey.zsh-theme b/themes/gallifrey.zsh-theme
 2index 252566f06152c6951ef104cff57505e7699e440a..7685470646a3d0082a188e27567b4fc301b37727 100644
 3--- a/themes/gallifrey.zsh-theme
 4+++ b/themes/gallifrey.zsh-theme
 5@@ -1,8 +1,11 @@
 6-# ZSH Theme - Preview: https://flic.kr/p/ZFvivf
 7-local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})"
 8+# ZSH Theme - Preview: https://github.com/robbyrussell/oh-my-zsh/wiki/Themes#gallifrey
 9+return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})"
10+host_color="%(!.%{$fg[red]%}.%{$fg[green]%})"
11 
12-PROMPT='%{$fg[green]%}%m%{$reset_color%} %2~ $(git_prompt_info)%{$reset_color%}%B»%b '
13+PROMPT="${host_color}%m%{$reset_color%} %2~ \$(git_prompt_info)%{$reset_color%}%B»%b "
14 RPS1="${return_code}"
15 
16 ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[yellow]%}‹"
17 ZSH_THEME_GIT_PROMPT_SUFFIX="› %{$reset_color%}"
18+
19+unset return_code host_color