Skip to content

Commit 680d720

Browse files
committed
contributors.py: Add aliases and process them
1 parent 5cc18fb commit 680d720

File tree

1 file changed

+22
-1
lines changed

1 file changed

+22
-1
lines changed

scripts/contributors.py

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,22 @@
1515
verbose = True
1616
# /--
1717

18+
# --- project specific configuration
19+
ALIASES = {
20+
'Richard Jones <[email protected]>':
21+
['richard',
22+
'Richard Jones <[email protected]>'],
23+
'Bernhard Reiter <[email protected]>':
24+
['Bernhard Reiter <[email protected]>',
25+
'Bernhard Reiter <[email protected]>'],
26+
'Ralf Schlatterbeck <[email protected]>':
27+
['Ralf Schlatterbeck <[email protected]>'],
28+
'Stefan Seefeld <[email protected]>':
29+
['Stefan Seefeld <[email protected]>'],
30+
'John P. Rouillard <[email protected]>':
31+
['rouilj'],
32+
}
33+
# /--
1834

1935

2036
def compress(years):
@@ -76,7 +92,12 @@ def compress(years):
7692
print("Sorting...")
7793
years = {} # year -> set(author1, author2, ...)
7894
names = {} # author -> set(years)
79-
for year,author in authorship:
95+
for year, author in authorship:
96+
# process aliases
97+
for name, aliases in ALIASES.items():
98+
if author in aliases:
99+
author = name
100+
break
80101
# years
81102
if not year in years:
82103
years[year] = set()

0 commit comments

Comments
 (0)