Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pretty OneLine Reversed #52

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions gitalias.txt
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,9 @@
# log with one line per item.
lo = log --oneline

# log with one line per item, reversed and pretty
ol = log --oneline --reverse --abbrev-commit --decorate --date=relative --format=format:'%C(bold cyan)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' -n 30
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already have log --oneline --reverse and in my opinion it's enough.

This alias has too many personal-style options. The colors suited for dark background but not light (at least not at my light grey terminal). Why --date=relative? Why -n 30? Why not 10 or 50?

My opinion is that such an alias is ok in your personal ~/.gitconfig but not suitable for general public.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Having a good one line log alias is a real help, especially those new to git. The default behaviour hides many salient features of the current status, particularly branch names. IMHO this is a useful behaviour. However, feel free to reject the PR if you do not wish to adopt it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I'm just an occasional contributor and reviewer I can neither accept nor reject the PR.


# log with patch generation.
lp = log --patch

Expand Down