CB Bailey <cb@xxxxxxxxxxxxx> writes: > From: CB Bailey <cbailey32@xxxxxxxxxxxxx> > > shortlog always respects the mailmap in its output. Pass the mailmap > into the revision walker to allow the mailmap to be used with revision > limiting options such as '--author'. I am a bit torn on this. If an author of interest has entries in the mailmap, with the same name but three or more different e-mail addresses, you could do $ git shortlog --author=junio@xxxxxxxxxx --author=junio@xxxxxxxxxxx to find commits by the author under these two addresses, and exclude commits by the same author made under other addresses. With this patch applied, it becomes no longer possible, and you can only look for commits written under all of my identities, or none of them, which is a minor annoyance. But more importantly, the user now needs to know which one is the "canonical" spelling of the author's ident [*1*]. Asking for commits written by junio@xxxxxxxxxx will not yield any result with the patch applied, no? For the author in the above example, luckily, AUTHOR_NAME is the same and unique, so without your patch, you could still do $ git shortlog --author="Junio C" to grab all of them, but there may be authors for whom there is no catch-all substring that would match all of the idents they ever used but still unique enough to match only that author, and I do agree that the new feature proposed by the patch in question would have uses in such a case. Which nudges me to say that there needs a way to ask for the original behaviour, disabling the rewriting of commit author identity before --author filter kicks in. There may also need a way to ask omitting mailmap processing even at the output phase. I do not think it is a particularly interesting feature to be able to ask for my commits under only two of my identities [*2*], but as long as that "feature" exists, it also should be possible to see the result of that "feature" more clearly by not merging them into a single list. "shortlog --no-use-mailmap" may be a way to do so, but unlike "log", the command currently does not take the "--[no-]use-mailmap" option. [Footnote] *1* Passing the query string given as --author=... through the mailmap machinery _might_ be a possible ingredient to solve "the user needs to know the caonical spelling of the author ident" issue this patch has, but I do not think it generally is possible (e.g. how would you rewrite --author='.*@kernel.org'). *2* In other words, I think the loss of "find only my @kernel.org and @twinsun.com commits" is mere annoyance and people can live with it. But I think "you must look for gitster@xxxxxxxxx, and looking for junio@xxxxxxxxxx will not find my commits made under that identity" is a show stopper. That is why I use a very weak "may also need" to this "optionally not using mailmap at all" feature.