Browse code

Remove unused colors and use original prompt color

Adam Lindberg authored on 07/06/2011 at 13:28:43
Showing 1 changed files
... ...
@@ -6,23 +6,17 @@
6 6
 
7 7
 # Color shortcuts
8 8
 R=$fg[red]
9
-Y=$fg[yellow]
10 9
 G=$fg[green]
11 10
 M=$fg[magenta]
12
-W=$fg[white]
13
-B=$fg[black]
14 11
 RB=$fg_bold[red]
15 12
 YB=$fg_bold[yellow]
16
-GB=$fg_bold[green]
17
-MB=$fg_bold[magenta]
18
-WB=$fg_bold[white]
19
-BB=$fg_bold[black]
13
+BB=$fg_bold[blue]
20 14
 RESET=$reset_color
21 15
 
22 16
 if [ "$(whoami)" = "root" ]; then
23 17
     PROMPTCOLOR="%{$RB%}" PREFIX="-!-";
24 18
 else
25
-    PROMPTCOLOR="%{$BB%}" PREFIX="---";
19
+    PROMPTCOLOR="" PREFIX="---";
26 20
 fi
27 21
 
28 22
 local return_code="%(?..%{$R%}%? ↵%{$RESET%})"
... ...
@@ -75,7 +69,8 @@ function custom_git_prompt() {
75 75
   echo "$ZSH_THEME_GIT_PROMPT_PREFIX${ref#refs/heads/}$(parse_git_dirty)$(git_prompt_ahead)$(custom_git_prompt_status)$ZSH_THEME_GIT_PROMPT_SUFFIX"
76 76
 }
77 77
 
78
-PROMPT='${PROMPTCOLOR}$PREFIX %2~ $(custom_git_prompt)%{$M%}%B»%b%{$RESET%} '
78
+# %B sets bold text
79
+PROMPT='%B$PREFIX %2~ $(custom_git_prompt)%{$M%}%B»%b%{$RESET%} '
79 80
 RPS1="${return_code}"
80 81
 
81 82
 ZSH_THEME_GIT_PROMPT_PREFIX="%{$YB%}‹"