git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Cornelius Weig <cornelius.weig@tngtech.com>
Cc: Stefan Beller <sbeller@google.com>,
	"git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: [RFC] mailmap.blob overrides default .mailmap
Date: Wed, 8 Feb 2017 14:50:22 -0500	[thread overview]
Message-ID: <20170208195022.6kqpgit3lkvskxta@sigill.intra.peff.net> (raw)
In-Reply-To: <53836bcd-1d4d-13fb-a523-1258017d19c9@tngtech.com>

On Tue, Feb 07, 2017 at 11:45:31PM +0100, Cornelius Weig wrote:

> On the other hand, a checked-in .mailmap file and a mailmap-blob are
> both as in-history as the other to me. Now consider the following
> settings:

I think it depends how you use them. You could point mailmap.blob to
some other ref entirely (even one that you fetched from another
repository).

I'd expect normal use to point it to HEAD:.mailmap, though (and that was
certainly the use case I wrote it for). On the other hand, the point of
pointing it to that particular blob is that it works even when you
_don't_ have a checkout (and this kicks in automatically in a bare
repo).

> $ git config --unset mailmap.file
> $ git config mailmap.blob HEAD:.mailmap
> $ sed -i 's:peff@peff.com:no-valid-address:' .mailmap
> $ git log -1 --author 'Jeff King'

In case anybody wants to experiment, there are a bunch of things that
make this a non-working example (at least on git.git):

  - my address is actually peff.net :)

  - There mailmap which mentions peff.net maps peff@github.com to
    peff.net, so this change would require --author=peff@github.com.

  - We don't apply mailmaps for the default output of "git log". You can
    format with "%aN %aE", or just use "git shortlog -ns --author=peff"
    which does map.

But that aside, yeah, you can make an argument to expect one way or the
other, depending on the situation you set up. I don't have a strong
feeling about it, but my gut feeling is that no ordering is
significantly better than the other, and that puts me in favor of
leaving it as-is purely out of inertia and backwards-compatibility.

-Peff

      reply	other threads:[~2017-02-08 19:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-07 11:56 [RFC] mailmap.blob overrides default .mailmap Cornelius Weig
2017-02-07 17:27 ` Stefan Beller
2017-02-07 19:28   ` Jeff King
2017-02-07 22:45     ` Cornelius Weig
2017-02-08 19:50       ` Jeff King [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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170208195022.6kqpgit3lkvskxta@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=cornelius.weig@tngtech.com \
    --cc=git@vger.kernel.org \
    --cc=sbeller@google.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).