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

Re: [Bug] --simplify-by-decoration prints undecorated commit

From
Jeff King <peff@peff.net>
Date
Dec 18, 2024, 12:08 UTC
Message-ID
<20241218120831.GA695807@coredump.intra.peff.net>
In-Reply-To
<CAEtHj8AXKrQfyAW9FSv6yC-8GF1AkPixMFjSye+B51pJ4fOtWA@mail.gmail.com>
On Mon, Dec 16, 2024 at 04:09:07PM +0100, Aleksander Korzyński wrote:
> # Now, let's try --simplify-by-decoration on another commit
> $ git log -1 --simplify-by-decoration --oneline 1e3ef455cc
> 025a87d9db Merge branch 'master' into master
> # The above output seems incorrect, because the commit isn't decorated
Yes, but it's a merge commit. From "git help log":
  Note that extra commits can be shown to give a meaningful history.
Try:
  git log --simplify-by-decoration --oneline --graph 1e3ef455cc

and you'll see that there are commits along both parent branches, and thus we show the merge.

There are some other options listed after that for changing which commits are shown ("The following options affect the way the simplification is performed"). But I don't think there is one that will show only the decorated commits (however, I could be wrong; I've only ever used these options to show _more_ commits, not fewer).

-Peff
Previous: Aleksander KorzyńskiNext: Aleksander Korzyński
Message 2 of 3 in “[Bug] --simplify-by-decoration prints undecorated commit”
  1. Aleksander KorzyńskiDec 16, 2024
  2. Jeff KingDec 18, 2024
  3. Aleksander KorzyńskiDec 20, 2024

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.