From: Junio C Hamano <gitster@pobox.com>
To: Jacob Keller <jacob.e.keller@intel.com>
Cc: git@vger.kernel.org, Jacob Keller <jacob.keller@gmail.com>,
Anthony Nguyen <anthony.l.nguyen@intel.com>
Subject: Re: [PATCH] format-patch: add support for mailmap file
Date: Wed, 14 Aug 2024 14:53:04 -0700 [thread overview]
Message-ID: <xmqq4j7mydof.fsf@gitster.g> (raw)
In-Reply-To: <20240813-jk-support-mailmap-git-format-patch-v1-1-1aea690ea5dd@gmail.com> (Jacob Keller's message of "Tue, 13 Aug 2024 14:45:22 -0700")
Jacob Keller <jacob.e.keller@intel.com> writes:
> diff --git a/builtin/log.c b/builtin/log.c
> index 4d4b60caa76a..94560add6fbc 100644
> --- a/builtin/log.c
> +++ b/builtin/log.c
> @@ -975,6 +975,7 @@ struct format_config {
> struct log_config log;
> enum thread_level thread;
> int do_signoff;
> + int use_mailmap;
As we share the "--[no-]mailmap" option from the command line with
"git log", shouldn't we be able to reuse log.use_mailmap_config as
well without adding yet another member to the struct? "git log"
defaults use_mailmap_config to true, but this command would want to
default it to false to avoid disrupting existing users, or
something, perhaps?
> diff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt
> index 8708b3159309..f3de349990bf 100644
> --- a/Documentation/git-format-patch.txt
> +++ b/Documentation/git-format-patch.txt
> @@ -30,6 +30,7 @@ SYNOPSIS
> [--range-diff=<previous> [--creation-factor=<percent>]]
> [--filename-max-length=<n>]
> [--progress]
> + [(--mailmap|--no-mailmap|--use-mailmap|--no-use-mailmap)]
We seem to say "[--[no-]cover-letter]" to abbreviate, and because
"--[no-]use-mailmap" is merely a synonym, shouldn't it be sufficient
to say
[--[no-]mailmap]
without any other frills? I find the use of the (al|terna|tive)
here especially annoying, as it is not like it is an error if you
give "--mailmap" and then say "--no-mailmap" later on the same
command line---it's just the usual "last one wins".
I haven't decided what my response to Peff's concern on the fallout
to "rebase --apply". On one hand, those who conciously choose to
rebase by creating patches and applying them would find it puzzling
if it did not honor format.mailmap setting. But I would not be
strongly opposed if we hardcoded to pass "--no-mailmap" to the
internal invocation of "format-patch", just like we hardcode "-k"
and other options and justified it with "the use of format-patch is
a mere implementation detail".
Thanks.
prev parent reply other threads:[~2024-08-14 21:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-13 21:45 [PATCH] format-patch: add support for mailmap file Jacob Keller
2024-08-13 22:45 ` Josh Steadmon
2024-08-14 0:20 ` Jacob Keller
2024-08-14 7:26 ` Jeff King
2024-08-14 17:43 ` Jacob Keller
2024-08-14 19:12 ` Junio C Hamano
2024-08-14 21:53 ` Junio C Hamano [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqq4j7mydof.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=anthony.l.nguyen@intel.com \
--cc=git@vger.kernel.org \
--cc=jacob.e.keller@intel.com \
--cc=jacob.keller@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).