Subject: Re: [PATCH 0/3] add a message-id header to git

From: Junio C Hamano <[email-masked]>
Date: Thu, 16 Oct 2025 13:32:45 -0700

James Bottomley <[email-masked]> writes:

> There has been some debate in the kernel community about how to link
> commits back to email, which is the basis of a lot of scripting we do
>
> https://lore.kernel.org/ksummit/[email-masked]/
>
> However, this problem is one that goes beyond the kernel, so having
> git always track the message-id of the email used to create the commit
> will be useful beyond our tools as well.  The design of this
> message-id header is that it never shows up except in --pretty=raw
> output, so it will never be ordinarily visible, but can be extracted
> by scripts.  Some projects use the -m flag of git-am to add the
> Message-Id to the trailers and for backwards compatibility, this
> functionality is not changed although it is hoped that it is now
> redundant.

I am perfectly fine with mailinfo changes and it is OK to add it to
commit trailer, but to the commit object header?  Having to maintain
an extra header is a headache, in that you have to worry about what
rebases and cherry-picks would do to them.  Please don't.

I haven't carefully read [2/3] yet, but do we now forbid to run the
poor-man's rebase "git format-patch ... | git am" pipeline by
insisting that state->msg_id to exist in parse_mail()?  The output
of format-patch over existing commits may not have the message-id
headers.