Skip to contentSkip to conversation

get_maintainer.pl and .mailmap entries with more than 2 addresses

PATCH Joe Perches 4 participants 5 messages Aug 2, 2016 – Aug 3, 2016 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

Hello Florian.

There is at least an oddity with get_maintainer handling of a .mailmap entry form.

For instance:

Mauro's .mailmap entry is:
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>

Is this a valid form?

get_maintainer output for Mauro is:

$ ./scripts/get_maintainer.pl drivers/media/ -f
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> (maintainer:MEDIA INPUT INFRASTRUCTURE (V4L/DVB))

I believe the Mauro's and Shuah's .mailmap entries are improper and should be changed, but I'm not completely aware of git .mailmap handling and the documentation seems weakly specified.

https://git-scm.com/docs/git-check-mailmap

Maybe get_maintainer.pl needs a change or perhaps this patch is appropriate.
---
 .mailmap | 12 ++++++++++--

 1 file changed, 10 insertions(+), 2 deletions(-)
.mailmap +0 -0
index c0d5704..c7f92ca 100644
@@ -96,7 +96,12 @@ Linus Lüssing <[email protected]> <[email protected]>

 Linus Lüssing <[email protected]> <[email protected]>
 Mark Brown <[email protected]>
 Matthieu CASTET <[email protected]>
-Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> +Mauro Carvalho Chehab <[email protected]> <[email protected]>
+Mauro Carvalho Chehab <[email protected]> <[email protected]>
+Mauro Carvalho Chehab <[email protected]> <[email protected]>
+Mauro Carvalho Chehab <[email protected]> <[email protected]>
+Mauro Carvalho Chehab <[email protected]> <[email protected]>
+Mauro Carvalho Chehab <[email protected]> <[email protected]>
 Matt Ranostay <[email protected]> Matthew Ranostay <[email protected]>
 Matt Ranostay <[email protected]> <[email protected]>
 Mayuresh Janorkar <[email protected]>
@@ -132,7 +137,10 @@ Santosh Shilimkar <[email protected]>
 Sascha Hauer <[email protected]>
 S.Çağlar Onur <[email protected]>
 Shiraz Hashim <[email protected]> <[email protected]>
-Shuah Khan <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>
+Shuah Khan <[email protected]> <[email protected]>
+Shuah Khan <[email protected]> <[email protected]>
+Shuah Khan <[email protected]> <[email protected]>
+Shuah Khan <[email protected]> <[email protected]>
 Simon Kelley <[email protected]>
 Stéphane Witzmann <[email protected]>
 Stephen Hemminger <[email protected]>

#1 lore raw
Quoted 11 lines · Joe Perches

Hello Florian.

There is at least an oddity with get_maintainer handling of a .mailmap entry form.

For instance:

Mauro's .mailmap entry is:
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>

Is this a valid form?

I do not think so, according to "git shortlog --help" (the canonical source of the document is Documentation/mailmap.txt, but shortlog doc includes it). Here is the relevant bits.

In the simple form, each line in the file consists of the canonical real name of an author, whitespace, and an email address used in the commit (enclosed by '<' and '>') to map to the name. For example:
--
Proper Name <[email protected]>
--

The more complex forms are:
--
<[email protected]> <[email protected]>
--
which allows mailmap to replace only the email part of a commit, and:
--
Proper Name <[email protected]> <[email protected]>
--
which allows mailmap to replace both the name and the email of a commit matching the specified commit email address, and:
--
Proper Name <[email protected]> Commit Name <[email protected]>
--
which allows mailmap to replace both the name and the email of a commit matching both the specified commit name and email address.

#3 lore raw
In reply to a message not in the archive
Quoted 52 lines · Florian Mickler

cc'd [email protected]  (Mauro, is your kernel.org address up?)

 Am Tue, 02 Aug 2016 09:36:21 -0700
schrieb Joe Perches <[email protected]>:

Quoted 22 lines

Hello Florian.
There is at least an oddity with get_maintainer handling of a .mailmap entry form.

For instance:

Mauro's .mailmap entry is:
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>

Is this a valid form?

get_maintainer output for Mauro is:

$ ./scripts/get_maintainer.pl drivers/media/ -f
Mauro Carvalho Chehab <[email protected]> <[email protected]>
<[email protected]> <[email protected]> <[email protected]>
<[email protected]> (maintainer:MEDIA INPUT INFRASTRUCTURE
(V4L/DVB))
Quoted 4 lines

I believe the Mauro's and Shuah's .mailmap entries are improper and should be changed, but I'm not completely aware of git .mailmap handling and the documentation seems weakly specified.

Hmm.. looking at Mauros last .mailmap commit it seems like your patch is ok for Mauro.

Although <[email protected]> and <[email protected]> are probably missing? (@Mauro)

$ git shortlog | grep "^Mauro C"
Mauro Carvalho Chehab (4404):
$ git log | grep "^Author:.*Mauro Carvalho Chehab" | sort | uniq -c
      2 Author: Mauro Carvalho Chehab <[email protected]>
    146 Author: Mauro Carvalho Chehab <[email protected]>
    645 Author: Mauro Carvalho Chehab <[email protected]>
    794 Author: Mauro Carvalho Chehab <[email protected]>
   2015 Author: Mauro Carvalho Chehab <[email protected]>
    448 Author: Mauro Carvalho Chehab <[email protected]>
    353 Author: Mauro Carvalho Chehab <[email protected]>
      1 Author: Mauro Carvalho Chehab <[email protected]>
Quoted 4 lines

Anyway, from a technical viewpoint your patches seem to fix the .mailmap entry as the author intended. (See Junio's Email for the documantation part)
But I would wait for the ack from Mauro and Shuah.

As far as I understand, a single entry with just their name and preferred email address would work too because the name parts are all spelled identically.

Acked-by
#4 lore raw
Quoted 53 lines · Joe Perches
Quoted 52 lines · Florian Mickler

cc'd [email protected] (Mauro, is your kernel.org address up?)

Am Tue, 02 Aug 2016 09:36:21 -0700
schrieb Joe Perches <[email protected]>:

Quoted 22 lines

Hello Florian.
There is at least an oddity with get_maintainer handling of a .mailmap entry form.

For instance:

Mauro's .mailmap entry is:
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>

Is this a valid form?

get_maintainer output for Mauro is:

$ ./scripts/get_maintainer.pl drivers/media/ -f
Mauro Carvalho Chehab <[email protected]> <[email protected]>
<[email protected]> <[email protected]> <[email protected]>
<[email protected]> (maintainer:MEDIA INPUT INFRASTRUCTURE
(V4L/DVB))
Quoted 4 lines

I believe the Mauro's and Shuah's .mailmap entries are improper and should be changed, but I'm not completely aware of git .mailmap handling and the documentation seems weakly specified.

Hmm.. looking at Mauros last .mailmap commit it seems like your patch is ok for Mauro.

Although <[email protected]> and <[email protected]> are probably missing? (@Mauro)

$ git shortlog | grep "^Mauro C"
Mauro Carvalho Chehab (4404):
$ git log | grep "^Author:.*Mauro Carvalho Chehab" | sort | uniq -c
      2 Author: Mauro Carvalho Chehab <[email protected]>
    146 Author: Mauro Carvalho Chehab <[email protected]>
    645 Author: Mauro Carvalho Chehab <[email protected]>
    794 Author: Mauro Carvalho Chehab <[email protected]>
   2015 Author: Mauro Carvalho Chehab <[email protected]>
    448 Author: Mauro Carvalho Chehab <[email protected]>
    353 Author: Mauro Carvalho Chehab <[email protected]>
      1 Author: Mauro Carvalho Chehab <[email protected]>
Quoted 10 lines
Quoted 4 lines

Anyway, from a technical viewpoint your patches seem to fix the .mailmap entry as the author intended. (See Junio's Email for the documantation part)
But I would wait for the ack from Mauro and Shuah.

As far as I understand, a single entry with just their name and preferred email address would work too because the name parts are all spelled identically.

I am fine with change to my entry. Thanks for fixing it.

thanks,
-- Shuah

Tested-by Giorgio Vazzana Acked-by
#5 lore raw
In reply to a message not in the archive

Em Wed, 03 Aug 2016 00:17:10 +0200
Florian Mickler <[email protected]> escreveu:

Quoted 1 line

cc'd [email protected] (Mauro, is your kernel.org address up?)

Yes, my kernel.org address is up. Better to keep it as the canonical address, as this is unlikely to change as it is not associated to an e-mail provider.

Quoted 31 lines

Am Tue, 02 Aug 2016 09:36:21 -0700
schrieb Joe Perches <[email protected]>:

Quoted 22 lines

Hello Florian.

There is at least an oddity with get_maintainer handling of a .mailmap entry form.

For instance:

Mauro's .mailmap entry is:
Mauro Carvalho Chehab <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]> <[email protected]>

Is this a valid form?

get_maintainer output for Mauro is:

$ ./scripts/get_maintainer.pl drivers/media/ -f
Mauro Carvalho Chehab <[email protected]> <[email protected]>
<[email protected]> <[email protected]> <[email protected]>
<[email protected]> (maintainer:MEDIA INPUT INFRASTRUCTURE
(V4L/DVB))
Quoted 4 lines

I believe the Mauro's and Shuah's .mailmap entries are improper and should be changed, but I'm not completely aware of git .mailmap handling and the documentation seems weakly specified.

Quoted 5 lines

Hmm.. looking at Mauros last .mailmap commit it seems like your patch is ok for Mauro.

Although <[email protected]> and <[email protected]> are probably missing? (@Mauro)

The [email protected] is indeed an old email that I used on my first submissions.

I don't know a [email protected] address... that looks really weird on my eyes...

Hmm...

$ git log --author "[email protected]"
commit fe8b671306c78a963934cb5d6e354178390b8c87
Author: Mauro Carvalho Chehab <[email protected]>
Date:   Thu Sep 30 14:46:47 2010 -0300

[media] saa7134: port Asus P7131 Hybrid to use the new rc-core

The rc map table were corrected thanks to Giorgio input and tests.

I don't remember the dirty details about such patch anymore... too many years ago. From the custody chain, I _suspect_ that Giorgio proposed a patch to be applied against the saa7134 driver, but the remote controller map table was moved to a separate file about 7 months before such patch by those changesets:

6686fa6917ca V4L/DVB: Break Remote Controller keymaps into modules 77b7422d48cd V4L/DVB: ir-common: move IR tables from ir-keymaps.c to a separate file

I likely rewrote his patch against the new driver, but somehow I mangled with the author name/email. In any case, [email protected] should not be associated with me.

Quoted 11 lines

<snip console research ... >

$ git shortlog | grep "^Mauro C"
Mauro Carvalho Chehab (4404):
$ git log | grep "^Author:.*Mauro Carvalho Chehab" | sort | uniq -c
      2 Author: Mauro Carvalho Chehab <[email protected]>
    146 Author: Mauro Carvalho Chehab <[email protected]>
    645 Author: Mauro Carvalho Chehab <[email protected]>
    794 Author: Mauro Carvalho Chehab <[email protected]>
   2015 Author: Mauro Carvalho Chehab <[email protected]>
    448 Author: Mauro Carvalho Chehab <[email protected]>
    353 Author: Mauro Carvalho Chehab <[email protected]>

All above are my e-mails. Let's point them all to [email protected].

Quoted 1 line

1 Author: Mauro Carvalho Chehab <[email protected]>

This one is mangled and doesn't belong to me. So, it shouldn't be at the .mailmap file.

Quoted 7 lines

</snip>

Anyway, from a technical viewpoint your patches seem to fix the .mailmap entry as the author intended. (See Junio's Email for the documantation part)
But I would wait for the ack from Mauro and Shuah.

With the above changes,

Thanks,
Mauro