Skip to content

Instantly share code, notes, and snippets.

@udayms
Forked from miebach/git-log-pretty
Created June 7, 2017 18:25
Show Gist options
  • Save udayms/204f00008e37c0c2e8f188e3dbd6af1c to your computer and use it in GitHub Desktop.
Save udayms/204f00008e37c0c2e8f188e3dbd6af1c to your computer and use it in GitHub Desktop.
pretty git log graph with coloured branches
# Visualizing branch topology in git on the commandline
git log --graph --oneline --full-history --all
git log --graph --full-history --all --pretty=format:"%h%x09%d%x20%s"
# With colors in Bash:
git log --graph --full-history --all --color --pretty=format:"%x1b[31m%h%x09%x1b[32m%d%x1b[0m%x20%s"
# thanks to Pavel Shved: http://stackoverflow.com/a/1838938
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment