Skip to content

Instantly share code, notes, and snippets.

@jacebrowning
Last active December 25, 2015 22:19
Show Gist options
  • Save jacebrowning/7048912 to your computer and use it in GitHub Desktop.
Save jacebrowning/7048912 to your computer and use it in GitHub Desktop.
Bash profile for OS X.
if [ -f `brew --prefix`/etc/bash_completion ]; then
. `brew --prefix`/etc/bash_completion
fi
# Git branch in prompt
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
# Git bash completion
if [ -f `brew --prefix`/etc/bash_completion ]; then
. `brew --prefix`/etc/bash_completion
fi
alias ll="ls -l"
alias nose=nosetests
alias e="subl -n ."
alias python=python3
export PROMPT_COMMAND='echo -ne "\033]0;${PWD##*/}\007"'
export PS1="\w\[\033[32m\]\$(parse_git_branch)\[\033[00m\] $ "
export PATH="/Library/Frameworks/Python.framework/Versions/2.7/bin:${PATH}"
export PATH="/Library/Frameworks/Python.framework/Versions/3.4/bin:${PATH}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment