Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ## Paste into ~/.bashrc
- ## Current Git Branch
- PS1="\u@\h:\w\`ruby -e \"print (%x{git branch 2> /dev/null}.grep(/^\*/).first || '').gsub(/^\* (.+)$/, '(\1)')\"\`$ "
- ## Current Git Branch with some colour. (Dark Blue and Red)
- PS1="\[\033[38m\]\u@\h\[\033[01;34m\] \w \[\033[31m\]\`ruby -e \"print (%x{git branch 2> /dev/null}.grep(/^\*/).first || '').gsub(/^\* (.+)$/, '(\1) ')\"\`\[\033[37m\]$\[\033[00m\] "
Add Comment
Please, Sign In to add comment