aboutsummaryrefslogtreecommitdiff
path: root/.bashrc
diff options
context:
space:
mode:
Diffstat (limited to '.bashrc')
-rw-r--r--.bashrc11
1 files changed, 10 insertions, 1 deletions
diff --git a/.bashrc b/.bashrc
index eea2543..55d8d66 100644
--- a/.bashrc
+++ b/.bashrc
@@ -54,8 +54,17 @@ __precmd()
# wrapping issues later in life. It is also *very* important to wrap
# things in double quotes for the PS1 coloring to be applied correctly!
+ PS1=
+
# Set the username, hostname and path
- PS1="\001$SHELLC_F_GREEN\002\u\001$SHELLC_RESET_COLOR_F\002"
+ if [[ 0 < $EUID ]]
+ then
+ PS1+="\001$SHELLC_F_GREEN\002"
+ else
+ PS1+="\001$SHELLC_F_RED\002"
+ fi
+
+ PS1+="\u\001$SHELLC_RESET_COLOR_F\002"
PS1+="\001$SHELLC_F_LIGHTGRAY\002@\001$SHELLC_RESET_COLOR_F\002"
PS1+="\001$SHELLC_F_MAGENTA\002\H\001$SHELLC_RESET_COLOR_F\002"
PS1+="\001$SHELLC_F_LIGHTGRAY\002:\001$SHELLC_RESET_COLOR_F\002"