From: Jeff King <peff@peff.net>
To: git@vger.kernel.org
Subject: [PATCH 0/2] mailmap from blobs
Date: Wed, 12 Dec 2012 05:58:23 -0500 [thread overview]
Message-ID: <20121212105822.GA15842@sigill.intra.peff.net> (raw)
I noticed recently that the GitHub contributions page for git.git did
not seem very accurate. The problem is that while it uses shortlog, it
does not respect .mailmap, because we do not have a working tree from
which to read the .mailmap.
This series adds a config option analogous to mailmap.file, but which
reads from a blob in the repository (so the obvious thing to set it to
is "HEAD:.mailmap" in a bare repo, and probably "master:.mailmap" if you
frequently want to traverse while on unrelated branches). The obvious
alternative is to checkout a temporary file of .mailmap and point
mailmap.file at it, but this is a bit more convenient.
A config option is perhaps not the most flexible way to access this. For
example, one could in theory want to pull the mailmap from the tip of
the history being traversed (e.g., because you have multiple unrelated
DAGs in a single repo). But that could also produce the _wrong_ results,
if you are looking at the shortlog of older history (e.g., when doing
"git shortlog v1.5.0..v1.5.5", you would still want to be using the
modern mailmap from "master").
By making it a config option, the simple, common case does the right
thing, and people with complex cases can use "git -c mailmap.blob=..."
to feed the appropriate map for the history they are traversing. If
somebody wants to do something fancier (like --mailmap-from-tip or
something), it would be easy to build on top later.
[1/2]: mailmap: refactor mailmap parsing for non-file sources
[2/2]: mailmap: support reading mailmap from blobs
-Peff
next reply other threads:[~2012-12-12 10:58 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-12 10:58 Jeff King [this message]
2012-12-12 10:59 ` [PATCH 1/2] mailmap: refactor mailmap parsing for non-file sources Jeff King
2012-12-12 11:04 ` [PATCH 2/2] mailmap: support reading mailmap from blobs Jeff King
2012-12-12 11:18 ` [PATCH 3/2] mailmap: clean up read_mailmap error handling Jeff King
2012-12-13 13:08 ` [PATCH 2/2] mailmap: support reading mailmap from blobs Jeff King
2012-12-12 17:54 ` [PATCH 0/2] " Junio C Hamano
2012-12-12 17:59 ` Jeff King
2012-12-13 13:04 ` Jeff King
2012-12-13 18:23 ` Junio C Hamano
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=20121212105822.GA15842@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
/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).