Skip to content

Instantly share code, notes, and snippets.

@asford
Created December 30, 2018 02:54
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 asford/7738ecd887ae0a48cf31b8e770dad4be to your computer and use it in GitHub Desktop.
Save asford/7738ecd887ae0a48cf31b8e770dad4be to your computer and use it in GitHub Desktop.
Git Log Aliases
[alias]
### Log formatting
#
# Commit graph
llog = log --pretty=format:'%x09%C(auto)%h %d %<(80,trunc)%s' --graph
# Short commit graph, abbreviated by reference
slog = log --pretty=format:'%x09%C(auto)%h %d %<(80,trunc)%s' --graph --simplify-by-decoration
# Upstream log
ulog = log --pretty=format:'%x09%C(auto)%h %d %<(80,trunc)%s' --graph @ @{u}
uslog = log --pretty=format:'%x09%C(auto)%h %d %<(80,trunc)%s' --graph --simplify-by-decoration @ @{u}
# Terse log, no commit message
tlog = log --pretty=format:'%x09%C(auto)%h %d' --graph @ @{u}
tslog = log --pretty=format:'%x09%C(auto)%h %d' --graph --simplify-by-decoration @ @{u}
# Terse logs, no commit message
nlog = log --graph --oneline --decorate origin/master..
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment