| ... | ... |
@@ -1,6 +1,8 @@ |
| 1 |
+if [ "$(whoami)" = "root" ]; then CARETCOLOR="red"; else CARETCOLOR="blue"; fi |
|
| 2 |
+ |
|
| 1 | 3 |
local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})"
|
| 2 | 4 |
|
| 3 |
-PROMPT='%m %{${fg_bold[blue]}%}:: %{$reset_color%}%{${fg[green]}%}%3~ $(git_prompt_info)%{${fg[blue]}%}»%{${reset_color}%} '
|
|
| 5 |
+PROMPT='%m %{${fg_bold[blue]}%}:: %{$reset_color%}%{${fg[green]}%}%3~ $(git_prompt_info)%{${fg_bold[$CARETCOLOR]}%}»%{${reset_color}%} '
|
|
| 4 | 6 |
|
| 5 | 7 |
RPS1="${return_code}"
|
| 6 | 8 |
|