tools.linux.kernel.org archive mirror
 help / color / mirror / Atom feed
* b4: workflow for selecting to/cc targets of individual patches
@ 2023-05-31 18:57 Maximilian Weigand
  2023-05-31 20:41 ` Nathan Chancellor
  2023-06-02 16:44 ` Konstantin Ryabitsev
  0 siblings, 2 replies; 4+ messages in thread
From: Maximilian Weigand @ 2023-05-31 18:57 UTC (permalink / raw)
  To: tools

Hi everyone,

as a very new and inexperienced patch submitter I am currently
struggling to properly prepare/submit a patch set where patches are
targeted at different maintainers and would be interested in the
proposed way to do this using b4:

My understanding (also from reading a bit in the tools archive) is that
the cover letter should be addressed to all maintainers and mailing
lists targeted in any of the patches, while individual patches should go
only to the maintainers (via To:) and lists (via Cc:) they are targeted at.

Using b4 prep --auto-to-cc is not an option here, as all To:/CC:
addresses in the cover letter will be used in all patches (my
understanding, based on b4 send --dry-run tests).

Therefore, the only way I currently see is to populate individual
commits/patches with To:/Cc: lines in their respective trailers, e.g.
based on suitable (manual) calls to get_maintainer.pl, such is used
internally by b4 prep --auto-to-cc. Is that the recommended way?

I have not seen many patches on the mailing lists that contain To:/Cc:
lines in their trailers and am wondering that behavior would be
acceptable? If yes, would it make sense to add functionality to b4 that
would populate individual patches with To:/Cc:, similar to --auto-to-cc
does for the cover letter?

Thank you very much for any help,

best regards

Maximilian

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: b4: workflow for selecting to/cc targets of individual patches
  2023-05-31 18:57 b4: workflow for selecting to/cc targets of individual patches Maximilian Weigand
@ 2023-05-31 20:41 ` Nathan Chancellor
  2023-06-02  8:28   ` Maximilian Weigand
  2023-06-02 16:44 ` Konstantin Ryabitsev
  1 sibling, 1 reply; 4+ messages in thread
From: Nathan Chancellor @ 2023-05-31 20:41 UTC (permalink / raw)
  To: Maximilian Weigand; +Cc: tools

Hi Maximilian,

On Wed, May 31, 2023 at 08:57:58PM +0200, Maximilian Weigand wrote:
> Hi everyone,
> 
> as a very new and inexperienced patch submitter I am currently
> struggling to properly prepare/submit a patch set where patches are
> targeted at different maintainers and would be interested in the
> proposed way to do this using b4:
> 
> My understanding (also from reading a bit in the tools archive) is that
> the cover letter should be addressed to all maintainers and mailing
> lists targeted in any of the patches, while individual patches should go
> only to the maintainers (via To:) and lists (via Cc:) they are targeted at.
> 
> Using b4 prep --auto-to-cc is not an option here, as all To:/CC:
> addresses in the cover letter will be used in all patches (my
> understanding, based on b4 send --dry-run tests).
> 
> Therefore, the only way I currently see is to populate individual
> commits/patches with To:/Cc: lines in their respective trailers, e.g.
> based on suitable (manual) calls to get_maintainer.pl, such is used
> internally by b4 prep --auto-to-cc. Is that the recommended way?
> 
> I have not seen many patches on the mailing lists that contain To:/Cc:
> lines in their trailers and am wondering that behavior would be
> acceptable? If yes, would it make sense to add functionality to b4 that
> would populate individual patches with To:/Cc:, similar to --auto-to-cc
> does for the cover letter?

I am not sure if this is the "recommended" way but what I have done in
the past is included the To and Cc trailers in the commit message of the
change in git with a '---' between my signoff and those trailers,
something like:

    <commit_title>

    <commit_message>

    <trailers>
    Signed-off-by: name <email>
    ---
    To: name <email>
    Cc: name <email>

You can see what it will look like if you flip through the patches here:

https://lore.kernel.org/20221228-drop-qunused-arguments-v2-0-9adbddd20d86@kernel.org/

I recommend adding them to the scissor area (i.e., include them after an
explicit '---' in the commit message versus adding them to the
<trailers> area) so that when the patch is actually applied, they do not
get included in git history, as they can result in extra spam if any
patches end up in a stable release.

It might make sense to have some way for b4 to do this like with
'--auto-to-cc' but I would generally say it is rare to need to send a
series with a conglomeration of patches with a single cover letter to
multiple maintainers, unless you are doing a massive treewide change, in
which case, it is often better to break down the series per subsystem,
which can help with tracking and sending new revisions. That might just
be my opinion though :)

Hope this is helpful, cheers!
Nathan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: b4: workflow for selecting to/cc targets of individual patches
  2023-05-31 20:41 ` Nathan Chancellor
@ 2023-06-02  8:28   ` Maximilian Weigand
  0 siblings, 0 replies; 4+ messages in thread
From: Maximilian Weigand @ 2023-06-02  8:28 UTC (permalink / raw)
  To: Nathan Chancellor; +Cc: tools

Hi Nathan,
> I am not sure if this is the "recommended" way but what I have done in
> the past is included the To and Cc trailers in the commit message of the
> change in git with a '---' between my signoff and those trailers,
> something like:
> 
>     <commit_title>
> 
>     <commit_message>
> 
>     <trailers>
>     Signed-off-by: name <email>
>     ---
>     To: name <email>
>     Cc: name <email>
> 
> You can see what it will look like if you flip through the patches here:
> 
> https://lore.kernel.org/20221228-drop-qunused-arguments-v2-0-9adbddd20d86@kernel.org/
> 
> I recommend adding them to the scissor area (i.e., include them after an
> explicit '---' in the commit message versus adding them to the
> <trailers> area) so that when the patch is actually applied, they do not
> get included in git history, as they can result in extra spam if any
> patches end up in a stable release.
> 
> It might make sense to have some way for b4 to do this like with
> '--auto-to-cc' but I would generally say it is rare to need to send a
> series with a conglomeration of patches with a single cover letter to
> multiple maintainers, unless you are doing a massive treewide change, in
> which case, it is often better to break down the series per subsystem,
> which can help with tracking and sending new revisions. That might just
> be my opinion though :)

Thanks for those clarifications. I see now that most small submissions
(such as mine) probably do not require separate To/CC recipients and
that correspondingly it does not make much sense to implement something
like that in b4.

Cheers

Maximilian

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: b4: workflow for selecting to/cc targets of individual patches
  2023-05-31 18:57 b4: workflow for selecting to/cc targets of individual patches Maximilian Weigand
  2023-05-31 20:41 ` Nathan Chancellor
@ 2023-06-02 16:44 ` Konstantin Ryabitsev
  1 sibling, 0 replies; 4+ messages in thread
From: Konstantin Ryabitsev @ 2023-06-02 16:44 UTC (permalink / raw)
  To: Maximilian Weigand; +Cc: tools

On Wed, May 31, 2023 at 08:57:58PM +0200, Maximilian Weigand wrote:
> My understanding (also from reading a bit in the tools archive) is that
> the cover letter should be addressed to all maintainers and mailing
> lists targeted in any of the patches, while individual patches should go
> only to the maintainers (via To:) and lists (via Cc:) they are targeted at.

My (very unscientific) polling that I held at the time when I was implementing
this suggested that pretty much all maintainers want to receive the entire
series, even if only a single patch out of 10 touches their subsystem. Seeing
the whole series allows them to better understand the patch in the context of
the larger change.

> Using b4 prep --auto-to-cc is not an option here, as all To:/CC:
> addresses in the cover letter will be used in all patches (my
> understanding, based on b4 send --dry-run tests).

I believe that you should just use this option and blame the tool if someone
complains (and I highly doubt that anyone will). :)

-K

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-06-02 16:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-31 18:57 b4: workflow for selecting to/cc targets of individual patches Maximilian Weigand
2023-05-31 20:41 ` Nathan Chancellor
2023-06-02  8:28   ` Maximilian Weigand
2023-06-02 16:44 ` Konstantin Ryabitsev

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).