Re: storing cover letter of a patch series?

38 views
Skip to first unread message

Martin Fick

unread,
Sep 10, 2015, 2:02:08 PM9/10/15
to Junio C Hamano, Jacob Keller, Git List, repo-d...@googlegroups.com
+repo-d...@googlegroups.com (to hit Gerrit developers
also)

On Thursday, September 10, 2015 09:28:52 AM Jacob Keller
<jacob....@gmail.com> wrote:
> does anyone know of any tricks for storing a cover letter
> for a patch series inside of git somehow? I'd guess the
> only obvious way currently is to store it at the top of
> the series as an empty commit.. but this doesn't get
> emailed as the cover letter...
...
> I really think it should be possible to store something
> somehow as a blob that could be looked up later.


On Thursday, September 10, 2015 10:41:54 AM Junio C Hamano
wrote:
>
> I think "should" is too strong here. Yes, you could
> implement that way. It is debatable if it is better, or
> a flat file kept in a directory (my-topic/ in the example
> above) across rerolls is more flexible, lightweight and
> with less mental burden to the users. --

As a Gerrit developer and user, I would like a way to
see/review cover letters in Gerrit. We have had many
internal proposals, most based on git notes, but we have
also used the empty commit trick. It would be nice if there
were some standard git way to do this so that Gerrit and
other tools could benefit from this standard. I am not
suggesting that git need to be modified to do this, but
rather that at least some convention be established.

-Martin


--
The Qualcomm Innovation Center, Inc. is a member of Code
Aurora Forum, hosted by The Linux Foundation

Jacob Keller

unread,
Sep 10, 2015, 2:56:48 PM9/10/15
to Martin Fick, Junio C Hamano, Git List, repo-d...@googlegroups.com
On Thu, Sep 10, 2015 at 11:02 AM, Martin Fick <mf...@codeaurora.org> wrote:
> On Thursday, September 10, 2015 10:41:54 AM Junio C Hamano
> wrote:
>>
>> I think "should" is too strong here. Yes, you could
>> implement that way. It is debatable if it is better, or
>> a flat file kept in a directory (my-topic/ in the example
>> above) across rerolls is more flexible, lightweight and
>> with less mental burden to the users. --
>
> As a Gerrit developer and user, I would like a way to
> see/review cover letters in Gerrit. We have had many
> internal proposals, most based on git notes, but we have
> also used the empty commit trick. It would be nice if there
> were some standard git way to do this so that Gerrit and
> other tools could benefit from this standard. I am not
> suggesting that git need to be modified to do this, but
> rather that at least some convention be established.
>
> -Martin
>

Having used gerrit, this would be useful as well. The "empty commit
message" thing sort of works, but has issues.

I don't know if this could be solved for gerrit at all without
modification to git, since you'd need something that can be sent to
the gerrit server and received by the client.

Some form of git-notes might work, ie: a git-notes on the first
commit, stored in some "standard" refs/notes/cover or similar.. but
this would depend on implementation of a standard way to share notes.

One alternative as well is to use a --no-ff merge commit which forces
the merge between the base and the tip of the series and contains the
contents.. but I don't believe gerrit really works well with merge
commits.

But again, Junio's solution will work great for emails workflow, which
is my primary usage.

Martin Fick

unread,
Aug 5, 2016, 5:20:05 PM8/5/16
to Junio C Hamano, Michael S. Tsirkin, Jacob Keller, Git List, repo-d...@googlegroups.com
On Friday, August 05, 2016 08:39:58 AM you wrote:
> * A new topic, when you merge it to the "lit" branch, you
> describe the cover as the merge commit message.
>
> * When you updated an existing topic, you tell a tool
> like "rebase -i -p" to recreate "lit" branch on top of
> the mainline. This would give you an opportunity to
> update the cover.

This is a neat idea. How would this work if there is no
merge commit (mainline hasn't moved)?
Reply all
Reply to author
Forward
0 new messages