git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Any way to make git-log to enumerate commits?

From
Andreas Schwab <schwab@linux-m68k.org>
Date
Dec 5, 2018, 15:43 UTC
Message-ID
<87sgzcyo6x.fsf@igel.home>
In-Reply-To
<CABPp-BHhYgBndaOjTC9-YQ5gNJXqaw21Hf=FZzyA7AKDQvN+0A@mail.gmail.com>
On Dez 05 2018, Elijah Newren <newren@gmail.com> wrote:
> Or, just use name-rev so it works with non-linear histories too:
>
> git log | git name-rev --refs=$(git symbolic-ref HEAD) --stdin | less

That wouldn't work for a detached HEAD, though, and you need to use --no-abbrev.

Andreas.
-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."
Previous: Elijah NewrenNext: Junio C Hamano
Message 4 of 7 in “Any way to make git-log to enumerate commits?”
  1. Konstantin KharlamovDec 5, 2018
  2. Konstantin KhomoutovDec 5, 2018
  3. Elijah NewrenDec 5, 2018
  4. Andreas SchwabDec 5, 2018
  5. Junio C HamanoDec 6, 2018
  6. Konstantin KhomoutovDec 6, 2018
  7. Junio C HamanoDec 7, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.