Skip to content

Instantly share code, notes, and snippets.

Cathal Browne cathal

View GitHub Profile
View .bash_profile.sh
# append the following to bash profile
# ~/.bash_profile or #~/.bashrc
export PATH="$PATH:~/bin"
@cathal
cathal / git_ps1.sh
Last active Aug 29, 2015
PS1 prompt that includes git branch + colour code for committed/uncommitted changes
View git_ps1.sh
# Customise BASH PS1 prompt to show current GIT branch, colour coded to inform user if there are any uncomitted changes.
# by Cathal Browne - http://ninjazebra.com
# Inspired by http://mediadoneright.com/content/ultimate-git-ps1-bash-prompt
### Detects if your current directory is a git repository
### If a git repository
#### Displays current branch name:
##### in green if no uncommited changes
You can’t perform that action at this time.