Changeset - a44228cd208b
[Not reviewed]
default
0 2 0
Mads Kiilerich - 6 years ago 2019-07-19 01:00:11
mads@kiilerich.com
Grafted from: c4c3edb97ca9
scripts: prepare for giving credit for contributions that have been integrated into other changesets
2 files changed with 8 insertions and 2 deletions:
0 comments (0 inline, 0 general)
scripts/contributor_data.py
Show inline comments
 
@@ -53,24 +53,30 @@ no_about = set(total_ignore)
 
# seems unclear if the copyright is personal or belongs to a company.
 
no_about.add(('Thayne Harbaugh <thayne@fusionio.com>', '2011'))
 
no_about.add(('Dies Koper <diesk@fast.au.fujitsu.com>', '2012'))
 
no_about.add(('Erwin Kroon <e.kroon@smartmetersolutions.nl>', '2012'))
 
no_about.add(('Vincent Caron <vcaron@bearstech.com>', '2012'))
 
# These contributors' contributions might be too small to be copyrightable:
 
no_about.add(('philip.j@hostdime.com', '2012'))
 
no_about.add(('Stefan Engel <mail@engel-stefan.de>', '2012'))
 
no_about.add(('Ton Plomp <tcplomp@gmail.com>', '2013'))
 
# Was reworked and contributed later and shadowed by other contributions:
 
no_about.add(('Sean Farley <sean.michael.farley@gmail.com>', '2013'))
 

	
 
# Contributors in about.html and CONTRIBUTORS not appearing in repository
 
# history:
 
other = [
 
    # Work folded into commits attributed to others:
 
]
 

	
 
# Preserve contributors listed in about.html but not appearing in repository
 
# history:
 
other_about = [
 
    ("2011", "Aparkar <aparkar@icloud.com>"),
 
    ("2010", "RhodeCode GmbH"),
 
    ("2011", "RhodeCode GmbH"),
 
    ("2012", "RhodeCode GmbH"),
 
    ("2013", "RhodeCode GmbH"),
 
]
 

	
 
# Preserve contributors listed in CONTRIBUTORS but not appearing in repository
 
# history:
scripts/update-copyrights.py
Show inline comments
 
@@ -118,35 +118,35 @@ def insert_entries(
 

	
 

	
 
def main():
 
    repo_entries = [
 
        (year, contributor_data.name_fixes.get(name) or contributor_data.name_fixes.get(name.rsplit('<', 1)[0].strip()) or name)
 
        for year, name in
 
        (line.strip().split(' ', 1)
 
         for line in os.popen("""hg log -r '::.' -T '{date(date,"%Y")} {author}\n'""").readlines())
 
        ]
 

	
 
    insert_entries(
 
        filename='kallithea/templates/about.html',
 
        all_entries=repo_entries + contributor_data.other_about,
 
        all_entries=repo_entries + contributor_data.other_about + contributor_data.other,
 
        no_entries=contributor_data.no_about,
 
        domain_extra=contributor_data.domain_extra,
 
        split_re=r'(?:  <li>Copyright &copy; [^\n]*</li>\n)*',
 
        normalize_name=lambda name: name.split('<', 1)[0].strip(),
 
        format_f=lambda years, name: '  <li>Copyright &copy; %s, %s</li>\n' % (nice_years(years, '&ndash;', ', '), name),
 
        )
 

	
 
    insert_entries(
 
        filename='CONTRIBUTORS',
 
        all_entries=repo_entries + contributor_data.other_contributors,
 
        all_entries=repo_entries + contributor_data.other_contributors + contributor_data.other,
 
        no_entries=contributor_data.total_ignore,
 
        domain_extra=contributor_data.domain_extra,
 
        split_re=r'(?:    [^\n]*\n)*',
 
        normalize_name=lambda name: name,
 
        format_f=lambda years, name: ('    %s%s%s\n' % (name, ' ' if years else '', nice_years(years))),
 
        )
 

	
 
    insert_entries(
 
        filename='kallithea/templates/base/base.html',
 
        all_entries=repo_entries,
 
        no_entries=contributor_data.total_ignore,
 
        domain_extra={},
0 comments (0 inline, 0 general)