git log --graph --pretty=format:'%C(red)%h%Creset -%C(yellow)%d%Creset %s %C(green)(%cr) %C(yellow)<%an>%Creset'
The format
option allows you to specify your own log output format:
Parameter | Details |
---|---|
%C(color_name) | option colors the output that comes after it |
%h or %H | abbreviates commit hash (use %H for complete hash) |
%Creset | resets color to default terminal color |
%d | ref names |
%s | subject [commit message] |
%cr | committer date, relative to current date |
%an | author name |