Skip to content

Instantly share code, notes, and snippets.

@npassaro
Created October 30, 2014 22:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save npassaro/61caecf9762ebad7b454 to your computer and use it in GitHub Desktop.
Save npassaro/61caecf9762ebad7b454 to your computer and use it in GitHub Desktop.
.bashrc prompt showing git branch and coloring
# Custom bash prompt via kirsle.net/wizards/ps1.html
source /usr/share/git-core/contrib/completion/git-prompt.sh
export PS1="[\[$(tput setaf 5)\]\u\[$(tput setaf 2)\]@\h\[$(tput setaf 6)\]\[$(tput bold)\] \W\[$(tput sgr0)\]\$(__git_ps1)]\\$ \[$(tput sgr0)\]"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment