bashrc: Light green for normal user and red for root, like with zsh.

This commit is contained in:
nyuszika7h 2011-10-29 12:31:14 +03:00 committed by Mika Suomalainen
parent 53a541825b
commit dab65be727
1 changed files with 7 additions and 0 deletions

7
bashrc
View File

@ -67,6 +67,13 @@ else
fi
unset color_prompt force_color_prompt
# check if we're root
if [[ $EUID == 0 ]]; then
PS1='\033[1;31m\u@\h:\w\$\033[0m '
else
PS1='\033[1;32m\u@\h:\w\$\033[0m '
fi
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)