Skip to content

Instantly share code, notes, and snippets.

@bascht
Created February 15, 2015 12:32
Show Gist options
  • Select an option

  • Save bascht/d23e6ef0b727d855c78b to your computer and use it in GitHub Desktop.

Select an option

Save bascht/d23e6ef0b727d855c78b to your computer and use it in GitHub Desktop.
[alias]
lol= 'log' '--oneline' '--graph' '--decorate'
lg1 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(bold white)— %an%C(reset)%C(bold yellow)%d%C(reset)' --abbrev-commit --date=relative
lg2 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(bold white)— %an%C(reset)' --abbrev-commit
log= 'log' '--decorate' '--pretty=full'
me = $GIT_AUTHOR_NAME
lg = log --pretty=format:'%Cred%h%Creset - %Cgreen(%cr)%Creset%C(yellow)%d%Creset %s %C(bold blue)<%an>%Creset' --abbrev-commit --graph
lg-me = !git lg --author=\"$GIT_AUTHOR_NAME\"
today-all = !git lg --all --since='12am'
lg-day = "!f() { git lg-me --all --after=\"${1-(date \"+%Y-%m-%d\")} 00:00\" --before=\"${1-(date \"+%Y-%m-%d\")} 23:59\"; }; f"
log-grep = "!f() { git log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' ${1-HEAD..HEAD} | grep ${2-\"Merge pull\"}; }; f"
ribbon = tag --force _ribbon origin/master
catchup = log --patch --reverse --topo-order _ribbon..origin/master
st = 'status'
rb = 'rebase'
f = 'fetch'
pl = 'pull'
ps = 'push'
co = 'checkout'
cod = 'checkout develop'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment