Date: Thu, 31 Dec 2020 14:14:33 -0800 From: John Baldwin <jhb@FreeBSD.org> To: Li-Wen Hsu <lwhsu@freebsd.org> Cc: git@freebsd.org Subject: Re: Thoughts on git commit mail Message-ID: <2bff94da-deb9-2410-b580-441eb31c8d40@FreeBSD.org> In-Reply-To: <CAKBkRUwP53fV3qGUgvDMyqbURtqQdqdTj3bvOsdc2Xya1s9now@mail.gmail.com> References: <f90b2357-f13a-44da-42b7-c439f033f218@FreeBSD.org> <CAKBkRUwP53fV3qGUgvDMyqbURtqQdqdTj3bvOsdc2Xya1s9now@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 12/16/20 2:23 AM, Li-Wen Hsu wrote: > On Wed, Dec 16, 2020 at 7:59 AM John Baldwin <jhb@freebsd.org> wrote: >> Putting 1-3 together for the commit in question would give the >> header below which I think is a bit more compact and similar to >> svn formatting in that all the metadata is in a single block >> without additional whitespace. >> >> commit d79b57d3cf7151e45216c0f8501cdb2eb7a3bd86 >> Author: Glen Barber <gjb@FreeBSD.org> >> Date: 2020-12-13 21:31:39 +0000 >> Branch: main >> URL: https://cgit.FreeBSD.org/doc/commit/?id=d79b57d3cf7151e45216c0f8501cdb2eb7a3bd86 > > This sounds good to me, the reason I have both Author and Committer > fields because I was thinking if we have pull request / merge > workflow, there will be more commits and pushes with different > author/committer/pusher, and the date of these three will be > different, the From and Date fields in mail header can only cover the > pusher. So seeing some cherry-picks now via MFCs, I do have one thought. Here is a MFC by rlibby of a commit I made in head: commit 939430f23771bb2bdd85337a58f5ba0757f60782 Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2020-08-31 21:55:25 +0000 Commit: Ryan Libby <rlibby@FreeBSD.org> CommitDate: 2020-12-31 19:56:33 +0000 I still find this a bit verbose, but I do find that the CommitDate is the Date I actually care about rather than the AuthorDate. Neither one is a "push date", but CommitDate is much closer to that. I think I am still fine with keeping the Author as the name and relying on the e-mail >From to serve as the 'Commit' (probably should be "Committer") field, so something like: commit 939430f23771bb2bdd85337a58f5ba0757f60782 Author: John Baldwin <jhb@FreeBSD.org> Date: 2020-12-31 19:56:33 +0000 Branch: stable/12 URL: https://cgit.FreeBSD.org/src/commit/?id=939430f23771bb2bdd85337a58f5ba0757f60782 The mix of fields for name and date is a bit odd though. Perhaps another alternative might be to elide the Author fields if the Author == Committer? That would keep a lean format when when the individuals are the same. For that suggestion, I think you would always show the two Commit fields ("Committer" and "CommitDate") and only show "Author" and "AuthorDate" if Author != Committer? This would still be verbose for the change I'm referencing here, but would collapse the detail a bit for the (current) common case of people committing or merging their own changes. -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2bff94da-deb9-2410-b580-441eb31c8d40>