Skip to content

Instantly share code, notes, and snippets.

@rhemz
Created February 27, 2017 19:08
Show Gist options
  • Save rhemz/15dafad16e814da6c67baa9b828efa03 to your computer and use it in GitHub Desktop.
Save rhemz/15dafad16e814da6c67baa9b828efa03 to your computer and use it in GitHub Desktop.
my git config
[user]
email = [email protected]
name = Russ Zeien
[color]
ui = auto
[alias]
com = commit
c = commit
a = add
co = checkout
br = branch
st = status
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative
new = !sh -c 'git log $1@{1}..$1@{0} "$@"'
assume = update-index --assume-unchanged
unassume = update-index --no-assume-unchanged
assumed = "!git ls-files -v | grep ^h | cut -c 3-"
snapshot = !git stash save "snapshot: $(date)" && git stash apply "stash@{0}"
ours = "!f() { git checkout --ours $@ && git add $@; }; f"
theirs = "!f() { git checkout --theirs $@ && git add $@; }; f"
prune-all = !git remote | xargs -n 1 git remote prune
undo-all = reset --hard
[diff]
algorithm = patience
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment