Bash Prompt Colours (Debian)

I find that the standard bash prompt colours in Debian are very bland and in addition I like to have the prompt in RED when logged in as root or if I’ve SU’d to root.

To do so you can modify the Bash configuration file ~/.bashrc as both your standard user account and then as the root user:
Standard User Console:
PS1=’${debian_chroot:+($debian_chroot)}[e[01;32m][email protected][e[00m]:w$ ‘

Root Console:
export PS1='[e[01;31m]h[e[00m]:w$ ‘

For more information see the following resources:
http://tldp.org/HOWTO/Bash-Prompt-HOWTO/x329.html
http://www.funtoo.org/en/articles/linux/tips/prompt/
http://linux-magazine.com/issues/2007/83/paint_your_bash/(kategorie)/0

Bookmark the permalink.