Skip to content

Instantly share code, notes, and snippets.

@oddnoc
Created August 7, 2012 00:47
Show Gist options
  • Save oddnoc/3280068 to your computer and use it in GitHub Desktop.
Save oddnoc/3280068 to your computer and use it in GitHub Desktop.
Handy git config settings
# Some of these settings came from http://cheat.errtheblog.com/s/git
[alias]
br = branch
brav = branch -avv
brv = branch -vv
ci = commit
co = checkout
contributors = shortlog -se
df = diff
history = log --decorate --abbrev-commit --name-status --graph
lol = log --graph --decorate --pretty=oneline --abbrev-commit
lola = log --graph --decorate --pretty=oneline --abbrev-commit --all
loland = log --graph --all --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ar%Creset%C(green bold)% d%Creset: %s'
lolnd = log --graph --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ar%Creset%C(green bold)% d%Creset: %s'
lolandd = log --graph --all --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ai%Creset%C(green bold)% d%Creset: %s'
lolndd = log --graph --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ai%Creset%C(green bold)% d%Creset: %s'
lp = log -p --patience
ls = log --pretty=format:'%Cred%h%Creset %C(yellow)%ci%Creset %s - %C(bold blue)%an%Creset'
pum = pull upstream master
slol = log --graph --decorate --pretty=oneline --abbrev-commit --simplify-by-decoration
slola = log --graph --decorate --pretty=oneline --abbrev-commit --simplify-by-decoration --all
sloland = log --graph --all --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ar%Creset%C(green bold)% d%Creset: %s' --simplify-by-decoration
slolandd = log --graph --all --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ai%Creset%C(green bold)% d%Creset: %s' --simplify-by-decoration
slolnd = log --graph --pretty=format:'%C(yellow bold)%h%Creset (%Cblue%an%Creset)%C(magenta)% ar%Creset%C(green bold)% d%Creset: %s' --simplify-by-decoration
ss = status -s
st = status
ru = remote update
rup = remote update -p
[color]
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = blue bold
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
[color "diff"]
whitespace = red reverse
[core]
whitespace=fix,indent-with-non-tab,trailing-space,cr-at-eol,tabwidth=4
autocrlf = input
quotepath = false
[merge]
conflictstyle = diff3
[branch]
autosetuprebase = always
[rerere]
enabled = 1
[log]
decorate = short
[gitflow "options"]
archivefeatures = true
[apply]
whitespace = nowarn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment