Add the current git branch to your bash prompt! In .bashrc
:
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[0;1;38;5;247m\]> \[\033[3;38;5;68m\]\W $(parse_git_branch)\[\033[00m\] '
else
PS1='${debian_chroot:+($debian_chroot)}\W $(parse_git_branch)\[\033[00m\] '