Re: [PATCH 1/1] get_maintainer.pl: add --cc option to produce comma separated list of emails

From: jim . cromie

Date: Thu Mar 19 2026 - 13:15:31 EST


On Thu, Mar 19, 2026 at 10:14 AM Joe Perches <joe@xxxxxxxxxxx> wrote:
>
> On Thu, 2026-03-19 at 10:06 -0600, Jim Cromie wrote:
> > ```
> > This new option works as follows:
> >
> > git send-email --cc=$(scripts/get_maintainer.pl -cc 0*.patch) 0*.patch
> >
> > A complementary patch has been sent to [git@xxxxxxxxxxxxxxx](mailto:git@xxxxxxxxxxxxxxx), allowing:
> >
> > git send-email --cc=scripts/get_maintainer.pl 0*.patch
>
> I think this is not particularly useful.
> Just use a script.

1. Efficiency (One-Shot vs. Per-Patch): Unlike --cc-cmd, which runs
once per patch file, this runs once for the entire series. For a large
series or
a slow script (like get_maintainer.pl), this is a performance
win and avoids redundant processing.
2. Dry-Run Integrity: By integrating it into send-email, the script
execution is part of the command's own logic. This ensures that
--dry-run
accurately reflects exactly what the script produced within the
context of the mailing operation.
3. Argument Deduplication: It eliminates the "Double-entry" problem
where you have to pass the patch list twice (once to the subshell and
once to git
send-email). This reduces the chance of a typo causing you to
send patches to the wrong set of maintainers if the lists get out of
sync.
4. Configuration Synergy: You can now set sendemail.cc =
./scripts/get_maintainer.pl in your .git/config. A shell wrapper can't
easily override or
augment the built-in recipient logic as cleanly as this does.

That last point seems a clear win.
Far less maintainer annoyance at not receiving the entire patchset.