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

Re: [PATCH] log: let --follow follow renames in merge commits

From
Miklos Vajna <vmiklos@collabora.com>
Date
May 20, 2026, 13:28 UTC
Message-ID
<ag2265RJal-tJLoW@collabora.com>
In-Reply-To
<xmqqo6ib7vlp.fsf@gitster.g>
Hi Elijah, Jeff,
On Tue, May 19, 2026 at 03:37:54PM +0900, Junio C Hamano <gitster@pobox.com> wrote:
> > :-) Should I just wait more or should I resend this?
> 
> Rather, ask other reviewers

I did a small improvement to how 'git log --follow' works, as in if the rename happens inside the merge commit itself, then the rename was detected "vs the first parent", but it wasn't detected "vs other parents", which is painful with a "subtree" merge commit.

I'm not sure if it adds value, but I can append a one-paragraph summary of Junio's comment in this thread to the end the commit message, to be more explicit that the inherent limitation of the current log follow design (single path, once a rename is detected, we only care about the new path) is not changed with the patch, this is just a fix patch so 'git log' works better, similar to how 'git blame' already does.

May I ask you to review the patch?
Thanks,
Miklos
Previous: Junio C HamanoNext: Jeff King
Message 14 of 18 in “log: let --follow follow renames in merge commits”
  1. log: let --follow follow renames in merge commitsMiklos Vajna, May 12, 2026
  2. Miklos VajnaMay 19, 2026
  3. Junio C HamanoMay 19, 2026
  4. Junio C HamanoMay 19, 2026
  5. log: improve --follow following renames for non-linear historyMiklos Vajna, Jun 8, 2026
  6. Junio C HamanoJun 8, 2026
  7. log: improve --follow following renames for non-linear historyMiklos Vajna, Jun 11, 2026
  8. Junio C HamanoJun 11, 2026
  9. log: improve --follow following renames for non-linear historyMiklos Vajna, Jun 15, 2026
  10. log: improve --follow following renames for non-linear historyMiklos Vajna, Jun 22, 2026
  11. Junio C HamanoJun 22, 2026
  12. Miklos VajnaJun 23, 2026
  13. Junio C HamanoJun 12, 2026
  14. Miklos VajnaMay 20, 2026
  15. Jeff KingMay 22, 2026
  16. log: improve --follow following renames in merge commitsMiklos Vajna, May 23, 2026
  17. Miklos VajnaMay 30, 2026
  18. Miklos VajnaJun 4, 2026

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.