Merge branch 'jk/mailmap-cleanup' into maint
* jk/mailmap-cleanup: contrib: update stats/mailmap script .mailmap: normalize emails for Linus Torvalds .mailmap: normalize emails for Jeff King .mailmap: fix broken entry for Martin Langhoff .mailmap: match up some obvious names/emails
This commit is contained in:
commit
ccc3ae799c
19
.mailmap
19
.mailmap
@ -9,7 +9,9 @@ Alex Bennée <kernel-hacker@bennee.com>
|
|||||||
Alexander Gavrilov <angavrilov@gmail.com>
|
Alexander Gavrilov <angavrilov@gmail.com>
|
||||||
Aneesh Kumar K.V <aneesh.kumar@gmail.com>
|
Aneesh Kumar K.V <aneesh.kumar@gmail.com>
|
||||||
Brian M. Carlson <sandals@crustytoothpaste.ath.cx>
|
Brian M. Carlson <sandals@crustytoothpaste.ath.cx>
|
||||||
|
Cheng Renquan <crquan@gmail.com>
|
||||||
Chris Shoemaker <c.shoemaker@cox.net>
|
Chris Shoemaker <c.shoemaker@cox.net>
|
||||||
|
Dan Johnson <computerdruid@gmail.com>
|
||||||
Dana L. How <danahow@gmail.com>
|
Dana L. How <danahow@gmail.com>
|
||||||
Dana L. How <how@deathvalley.cswitch.com>
|
Dana L. How <how@deathvalley.cswitch.com>
|
||||||
Daniel Barkalow <barkalow@iabervon.org>
|
Daniel Barkalow <barkalow@iabervon.org>
|
||||||
@ -18,14 +20,18 @@ David Kågedal <davidk@lysator.liu.se>
|
|||||||
David S. Miller <davem@davemloft.net>
|
David S. Miller <davem@davemloft.net>
|
||||||
Deskin Miller <deskinm@umich.edu>
|
Deskin Miller <deskinm@umich.edu>
|
||||||
Dirk Süsserott <newsletter@dirk.my1.cc>
|
Dirk Süsserott <newsletter@dirk.my1.cc>
|
||||||
|
Eric S. Raymond <esr@thyrsus.com>
|
||||||
Erik Faye-Lund <kusmabite@gmail.com> <kusmabite@googlemail.com>
|
Erik Faye-Lund <kusmabite@gmail.com> <kusmabite@googlemail.com>
|
||||||
Fredrik Kuivinen <freku045@student.liu.se>
|
Fredrik Kuivinen <freku045@student.liu.se>
|
||||||
|
Frédéric Heitzmann <frederic.heitzmann@gmail.com>
|
||||||
H. Peter Anvin <hpa@bonde.sc.orionmulti.com>
|
H. Peter Anvin <hpa@bonde.sc.orionmulti.com>
|
||||||
H. Peter Anvin <hpa@tazenda.sc.orionmulti.com>
|
H. Peter Anvin <hpa@tazenda.sc.orionmulti.com>
|
||||||
H. Peter Anvin <hpa@trantor.hos.anvin.org>
|
H. Peter Anvin <hpa@trantor.hos.anvin.org>
|
||||||
Horst H. von Brand <vonbrand@inf.utfsm.cl>
|
Horst H. von Brand <vonbrand@inf.utfsm.cl>
|
||||||
İsmail Dönmez <ismail@pardus.org.tr>
|
İsmail Dönmez <ismail@pardus.org.tr>
|
||||||
|
Jakub Narębski <jnareb@gmail.com>
|
||||||
Jay Soffian <jaysoffian+git@gmail.com>
|
Jay Soffian <jaysoffian+git@gmail.com>
|
||||||
|
Jeff King <peff@peff.net> <peff@github.com>
|
||||||
Joachim Berdal Haga <cjhaga@fys.uio.no>
|
Joachim Berdal Haga <cjhaga@fys.uio.no>
|
||||||
Johannes Sixt <j6t@kdbg.org> <johannes.sixt@telecom.at>
|
Johannes Sixt <j6t@kdbg.org> <johannes.sixt@telecom.at>
|
||||||
Johannes Sixt <j6t@kdbg.org> <j.sixt@viscovery.net>
|
Johannes Sixt <j6t@kdbg.org> <j.sixt@viscovery.net>
|
||||||
@ -41,12 +47,21 @@ Junio C Hamano <gitster@pobox.com> <junio@hera.kernel.org>
|
|||||||
Junio C Hamano <gitster@pobox.com> <junio@kernel.org>
|
Junio C Hamano <gitster@pobox.com> <junio@kernel.org>
|
||||||
Junio C Hamano <gitster@pobox.com> <junkio@cox.net>
|
Junio C Hamano <gitster@pobox.com> <junkio@cox.net>
|
||||||
Karl Hasselström <kha@treskal.com>
|
Karl Hasselström <kha@treskal.com>
|
||||||
|
Kevin Leung <kevinlsk@gmail.com>
|
||||||
Kent Engstrom <kent@lysator.liu.se>
|
Kent Engstrom <kent@lysator.liu.se>
|
||||||
Lars Doelle <lars.doelle@on-line ! de>
|
Lars Doelle <lars.doelle@on-line ! de>
|
||||||
Lars Doelle <lars.doelle@on-line.de>
|
Lars Doelle <lars.doelle@on-line.de>
|
||||||
Li Hong <leehong@pku.edu.cn>
|
Li Hong <leehong@pku.edu.cn>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@woody.linux-foundation.org>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@osdl.org>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@g5.osdl.org>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@evo.osdl.org>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@ppc970.osdl.org>
|
||||||
|
Linus Torvalds <torvalds@linux-foundation.org> <torvalds@ppc970.osdl.org.(none)>
|
||||||
Lukas Sandström <lukass@etek.chalmers.se>
|
Lukas Sandström <lukass@etek.chalmers.se>
|
||||||
Martin Langhoff <martin@laptop.org>
|
Marc-André Lureau <marcandre.lureau@gmail.com>
|
||||||
|
Mark Rada <marada@uwaterloo.ca>
|
||||||
|
Martin Langhoff <martin@laptop.org> <martin@catalyst.net.nz>
|
||||||
Martin von Zweigbergk <martinvonz@gmail.com> <martin.von.zweigbergk@gmail.com>
|
Martin von Zweigbergk <martinvonz@gmail.com> <martin.von.zweigbergk@gmail.com>
|
||||||
Michael Coleman <tutufan@gmail.com>
|
Michael Coleman <tutufan@gmail.com>
|
||||||
Michael J Gruber <git@drmicha.warpmail.net> <michaeljgruber+gmane@fastmail.fm>
|
Michael J Gruber <git@drmicha.warpmail.net> <michaeljgruber+gmane@fastmail.fm>
|
||||||
@ -63,11 +78,13 @@ Ralf Thielow <ralf.thielow@gmail.com> <ralf.thielow@googlemail.com>
|
|||||||
Ramsay Allan Jones <ramsay@ramsay1.demon.co.uk>
|
Ramsay Allan Jones <ramsay@ramsay1.demon.co.uk>
|
||||||
René Scharfe <rene.scharfe@lsrfire.ath.cx>
|
René Scharfe <rene.scharfe@lsrfire.ath.cx>
|
||||||
Robert Fitzsimons <robfitz@273k.net>
|
Robert Fitzsimons <robfitz@273k.net>
|
||||||
|
Robert Zeh <robert.a.zeh@gmail.com>
|
||||||
Sam Vilain <sam@vilain.net>
|
Sam Vilain <sam@vilain.net>
|
||||||
Santi Béjar <sbejar@gmail.com>
|
Santi Béjar <sbejar@gmail.com>
|
||||||
Sean Estabrooks <seanlkml@sympatico.ca>
|
Sean Estabrooks <seanlkml@sympatico.ca>
|
||||||
Shawn O. Pearce <spearce@spearce.org>
|
Shawn O. Pearce <spearce@spearce.org>
|
||||||
Steven Grimm <koreth@midwinter.com>
|
Steven Grimm <koreth@midwinter.com>
|
||||||
|
Tay Ray Chuan <rctay89@gmail.com>
|
||||||
Theodore Ts'o <tytso@mit.edu>
|
Theodore Ts'o <tytso@mit.edu>
|
||||||
Thomas Rast <trast@inf.ethz.ch> <trast@student.ethz.ch>
|
Thomas Rast <trast@inf.ethz.ch> <trast@student.ethz.ch>
|
||||||
Tony Luck <tony.luck@intel.com>
|
Tony Luck <tony.luck@intel.com>
|
||||||
|
@ -1,38 +1,70 @@
|
|||||||
#!/usr/bin/perl -w
|
#!/usr/bin/perl
|
||||||
my %mailmap = ();
|
|
||||||
open I, "<", ".mailmap";
|
|
||||||
while (<I>) {
|
|
||||||
chomp;
|
|
||||||
next if /^#/;
|
|
||||||
if (my ($author, $mail) = /^(.*?)\s+<(.+)>$/) {
|
|
||||||
$mailmap{$mail} = $author;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
close I;
|
|
||||||
|
|
||||||
my %mail2author = ();
|
use warnings 'all';
|
||||||
open I, "git log --pretty='format:%ae %an' |";
|
use strict;
|
||||||
while (<I>) {
|
use Getopt::Long;
|
||||||
chomp;
|
|
||||||
my ($mail, $author) = split(/\t/, $_);
|
|
||||||
next if exists $mailmap{$mail};
|
|
||||||
$mail2author{$mail} ||= {};
|
|
||||||
$mail2author{$mail}{$author} ||= 0;
|
|
||||||
$mail2author{$mail}{$author}++;
|
|
||||||
}
|
|
||||||
close I;
|
|
||||||
|
|
||||||
while (my ($mail, $authorcount) = each %mail2author) {
|
my $match_emails;
|
||||||
# %$authorcount is ($author => $count);
|
my $match_names;
|
||||||
# sort and show the names from the most frequent ones.
|
my $order_by = 'count';
|
||||||
my @names = (map { $_->[0] }
|
Getopt::Long::Configure(qw(bundling));
|
||||||
sort { $b->[1] <=> $a->[1] }
|
GetOptions(
|
||||||
map { [$_, $authorcount->{$_}] }
|
'emails|e!' => \$match_emails,
|
||||||
keys %$authorcount);
|
'names|n!' => \$match_names,
|
||||||
if (1 < @names) {
|
'count|c' => sub { $order_by = 'count' },
|
||||||
for (@names) {
|
'time|t' => sub { $order_by = 'stamp' },
|
||||||
print "$_ <$mail>\n";
|
) or exit 1;
|
||||||
|
$match_emails = 1 unless $match_names;
|
||||||
|
|
||||||
|
my $email = {};
|
||||||
|
my $name = {};
|
||||||
|
|
||||||
|
open(my $fh, '-|', "git log --format='%at <%aE> %aN'");
|
||||||
|
while(<$fh>) {
|
||||||
|
my ($t, $e, $n) = /(\S+) <(\S+)> (.*)/;
|
||||||
|
mark($email, $e, $n, $t);
|
||||||
|
mark($name, $n, $e, $t);
|
||||||
|
}
|
||||||
|
close($fh);
|
||||||
|
|
||||||
|
if ($match_emails) {
|
||||||
|
foreach my $e (dups($email)) {
|
||||||
|
foreach my $n (vals($email->{$e})) {
|
||||||
|
show($n, $e, $email->{$e}->{$n});
|
||||||
}
|
}
|
||||||
|
print "\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if ($match_names) {
|
||||||
|
foreach my $n (dups($name)) {
|
||||||
|
foreach my $e (vals($name->{$n})) {
|
||||||
|
show($n, $e, $name->{$n}->{$e});
|
||||||
|
}
|
||||||
|
print "\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
exit 0;
|
||||||
|
|
||||||
|
sub mark {
|
||||||
|
my ($h, $k, $v, $t) = @_;
|
||||||
|
my $e = $h->{$k}->{$v} ||= { count => 0, stamp => 0 };
|
||||||
|
$e->{count}++;
|
||||||
|
$e->{stamp} = $t unless $t < $e->{stamp};
|
||||||
|
}
|
||||||
|
|
||||||
|
sub dups {
|
||||||
|
my $h = shift;
|
||||||
|
return grep { keys($h->{$_}) > 1 } keys($h);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub vals {
|
||||||
|
my $h = shift;
|
||||||
|
return sort {
|
||||||
|
$h->{$b}->{$order_by} <=> $h->{$a}->{$order_by}
|
||||||
|
} keys($h);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub show {
|
||||||
|
my ($n, $e, $h) = @_;
|
||||||
|
print "$n <$e> ($h->{$order_by})\n";
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user