diff options
author | Brian Hong <brian@hongs.me> | 2019-01-31 08:57:37 -0500 |
---|---|---|
committer | Marc Cornellà <marc.cornella@live.com> | 2019-01-31 14:57:37 +0100 |
commit | 851899e59ea71ce8fbae738ec7aeb7a967585977 (patch) | |
tree | 750e4bc7fe7c0f79bd8e92194c747b1f629baa3a /themes/gallifrey.zsh-theme | |
parent | 83ce8d05dfefacf1d4a7fdc957f38b3bd6cba6b4 (diff) | |
download | zsh-851899e59ea71ce8fbae738ec7aeb7a967585977.tar.gz zsh-851899e59ea71ce8fbae738ec7aeb7a967585977.tar.bz2 zsh-851899e59ea71ce8fbae738ec7aeb7a967585977.zip |
theme/gallifrey: set color to red if root (#6203)
Diffstat (limited to 'themes/gallifrey.zsh-theme')
-rw-r--r-- | themes/gallifrey.zsh-theme | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/themes/gallifrey.zsh-theme b/themes/gallifrey.zsh-theme index 252566f06..768547064 100644 --- a/themes/gallifrey.zsh-theme +++ b/themes/gallifrey.zsh-theme @@ -1,8 +1,11 @@ -# ZSH Theme - Preview: https://flic.kr/p/ZFvivf -local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})" +# ZSH Theme - Preview: https://github.com/robbyrussell/oh-my-zsh/wiki/Themes#gallifrey +return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})" +host_color="%(!.%{$fg[red]%}.%{$fg[green]%})" -PROMPT='%{$fg[green]%}%m%{$reset_color%} %2~ $(git_prompt_info)%{$reset_color%}%B»%b ' +PROMPT="${host_color}%m%{$reset_color%} %2~ \$(git_prompt_info)%{$reset_color%}%B»%b " RPS1="${return_code}" ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[yellow]%}‹" ZSH_THEME_GIT_PROMPT_SUFFIX="› %{$reset_color%}" + +unset return_code host_color |