00bff0a9963d4b36e6afc968449781c727bfef3b

Author
James Smith <james@loopj.com>
Committer
James Smith <james@loopj.com>
Date

Message

Red prompt for remote hosts

Diff

 1diff --git a/themes/intheloop.zsh-theme b/themes/intheloop.zsh-theme
 2index c4736422dc72c94713a12828040ad2b924520a34..85b4a4d9583c1d3b1cce339e3bec467ea2c07e03 100644
 3--- a/themes/intheloop.zsh-theme
 4+++ b/themes/intheloop.zsh-theme
 5@@ -3,10 +3,16 @@
 6 
 7 local return_status="%{$fg[red]%}%(?..⏎)%{$reset_color%}"
 8 
 9+local host_color="green"
10+if [ -n "$SSH_CLIENT" ]; then
11+  local host_color="red"
12+fi
13+
14 PROMPT='
15-%{$fg_bold[grey]%}[%{$reset_color%}%{$fg_bold[green]%}%n@%m%{$reset_color%}%{$fg_bold[grey]%}]%{$reset_color%} %{$fg_bold[blue]%}%10c%{$reset_color%} $(git_prompt_info) $(git_remote_status)
16+%{$fg_bold[grey]%}[%{$reset_color%}%{$fg_bold[${host_color}]%}%n@%m%{$reset_color%}%{$fg_bold[grey]%}]%{$reset_color%} %{$fg_bold[blue]%}%10c%{$reset_color%} $(git_prompt_info) $(git_remote_status)
17 %{$fg_bold[cyan]%}❯%{$reset_color%} '
18 
19+
20 RPROMPT='${return_status}%{$reset_color%}'
21 
22 ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[grey]%}(%{$fg[red]%}"