Append this to your ~/.bashrc
:
export PS1='\[\033[01;32m\]\h\[\033[01;34m\] \w\[\033[31m\]$(__git_ps1 "(%s)") \[\033[01;34m\]$\[\033[00m\] '
Reload the changes by saying
source ~/.bashrc
For some customized prompts that also show the current Git prompt, see the examples section at the bottom of our bash prompt customizing card.
Posted by Martin Straub to makandra dev (2010-08-25 12:17)