Skip to content

Instantly share code, notes, and snippets.

@Jonty
Created May 21, 2016 11:34
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 Jonty/47f887a034f6c7f198928610f9f9546e to your computer and use it in GitHub Desktop.
Save Jonty/47f887a034f6c7f198928610f9f9546e to your computer and use it in GitHub Desktop.
/etc/gitconfig
[alias]
st = status
ci = commit
br = branch
co = checkout
df = diff
lg = log -p
tidy-remotes = !git remote prune origin
branch-name = !git branch | sed -e '/^[^*]/d' -e 's/^* //' -e 's/^master$/STOP_TRYING_TO_PUBLISH_MASTER_YOU_IDIOT/'
publish = !git push -u origin $(git branch-name)
unpublish = !git push origin :$(git branch-name)
undo-commit = reset --soft HEAD^
[core]
excludesfile = /etc/gitignore
[color]
UI = auto
diff = auto
[branch]
autosetuprebase = always
mergeoptions = --no-ff
[push]
default = upstream
[rerere]
enabled = 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment