Skip to content

Instantly share code, notes, and snippets.

@smerrell
Created April 6, 2011 16:13
Show Gist options
  • Save smerrell/905949 to your computer and use it in GitHub Desktop.
Save smerrell/905949 to your computer and use it in GitHub Desktop.
My ~/.gitconfig aliases
[alias]
# Git-tfs workflows
ct = tfs ct --build-default-comment
tfsrebase = !git stash && git checkout master && git tfs pull && git checkout @{-1} && git rebase master && git stash pop
tfsworkflow = !git checkout master && git tfs pull && git checkout @{-1} && git rebase master && git checkout master && git merge @{-1} --ff-only && git tfs ct --build-default-comment
# Github workflows
upmaster = !git checkout master && git fetch upstream && git merge upstream/master --ff-only && git push origin HEAD
uprebase = !git checkout master && git fetch upstream && git merge upstream/master --ff-only && git push origin HEAD && git checkout @{-1} && git rebase master
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative
lstat = log --relative --abbrev-commit --date=local --pretty=format:'%C(white)%h %C(cyan)%cr %C(green)by %cn %Creset%n%C(yellow)%cd%n%s' --stat
peeps = !git log --pretty=format:%aN | sort | uniq -c | sort -rn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment