Skip to content

Instantly share code, notes, and snippets.

@jimbru
Created September 22, 2015 01:22
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 jimbru/344e699fbcd85fead926 to your computer and use it in GitHub Desktop.
Save jimbru/344e699fbcd85fead926 to your computer and use it in GitHub Desktop.
@jimbru's ~/.bash_profile
export CLICOLOR=1
export EDITOR=/usr/local/bin/vim
export GREP_OPTIONS='--color=auto'
export PATH="/usr/local/heroku/bin:$PATH"
alias htop='sudo htop'
alias sl='ls'
alias gadd='git add'
alias gbr='git branch'
alias gbra='git branch -a'
alias gbs='git bisect'
alias gci='git commit'
alias gcia='git commit -a'
alias gco='git checkout'
alias gcom='git checkout master'
alias gdiff='git diff'
alias ggrep='git grep'
alias glog='git log'
alias gmrg='git merge'
alias gmv='git mv'
alias gpull='git pull'
alias gpush='git push'
alias grb='git rebase'
alias grbo='git rebase --onto'
alias greset='git reset'
alias grm='git rm'
alias gshow='git show'
alias gst='git status'
alias gsub='git submodule'
alias gup='git pull'
function grbon {
grbo $1 HEAD~$2
}
function grbo1 {
grbon $1 1
}
function grbo2 {
grbon $1 2
}
function gbdiff {
git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative ${1}..${2}
}
# Superpowered git log
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%C(bold blue)<%an>%Creset' --abbrev-commit"
# Quick way to rebuild the Launch Services database and get rid of duplicates in the Open With submenu.
alias fixopenwith='/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user'
# Launch iOS Simulator
alias iossim='open /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment