Last active
April 12, 2024 20:13
-
-
Save BibMartin/3d8bc449ca2f93d4cf90 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git config --global alias.lola "log --graph --decorate --pretty=oneline --abbrev-commit --all" |
Something like this might do what you want. You can of course change the color, remove the date (%ad), or change the date format (--date) to match what you want. The format specifiers are documented at https://git-scm.com/docs/git-log#_pretty_formats.
git log --graph --pretty='format:%C(auto)%h %d %s %C(green)%an%C(bold blue) %ad' --all --date=relative
The %an
format specifier is for the author name (%cn
would be the committer name).
So, this could be a good option:
git config --global alias.lola "log --graph --decorate --pretty='format:%C(auto)%h %d %s %C(green)%an%C(bold blue) %ad' --abbrev-commit --all --date=relative"
It works very well for me.
Yep. I've since tweaked my to:
git log --graph --pretty='format:%C(auto)%h %d %s %C(green)(%ad) %C(cyan)<%an>' --abbrev-commit --all --date=relative
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Could you please tell me the argument to show "committer's name" as well?