Skip to content

Instantly share code, notes, and snippets.

@mateuszgachowski-snippets
Created December 4, 2013 18:10
Show Gist options
  • Save mateuszgachowski-snippets/7792517 to your computer and use it in GitHub Desktop.
Save mateuszgachowski-snippets/7792517 to your computer and use it in GitHub Desktop.
Bash: Sample .bash_profile
# Bash #
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
PS1='\[\033[01;32m\]\u@\[\033[01;36m\] \W \[\033[01;33m\]$(parse_git_branch)\[\033[01;34m\] \$\[\033[00m\] '
# Aliases #
alias ls='ls -G -S -F'
alias ..='cd ..'
alias sublime='/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl'
alias cato='pygmentize -g'
# Z #
. ~/.termscripts/z/z.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment