Skip to content

Commit 3bcb5be

Browse files
committed
Mark badge-worthy changes in jsondiff
1 parent 5323e10 commit 3bcb5be

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

docs/update_portingdb.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ The following steps are needed to update pordingdb data. You can run them all wi
7272

7373
(venv) $ git show
7474

75-
For "idle/mispackaged -> released/legacy-leaf/py3-only"), award badges: add new entries to `data/badges.txt`.
75+
For changes marked ♥, award badges: add new entries to `data/badges.txt`.
7676

7777
Find responsible people at https://src.fedoraproject.org/rpms/python-FOO/commits/master
7878

scripts/jsondiff.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,17 @@ def main(first_filename, second_filename):
124124
print()
125125

126126
for change, packages in sorted(status_changes.items()):
127-
print(term.blue('**{}** → **{}** ({})'.format(*change, len(packages))))
127+
change_from, change_to = change
128+
if (
129+
change_from in {'idle', 'mispackaged'}
130+
and change_to in {'released', 'legacy-leaf', 'py3-only'}
131+
):
132+
badge_marker = '♥'
133+
else:
134+
badge_marker = ''
135+
print(term.blue('**{}** → **{}** ({}) {}'.format(
136+
*change, len(packages), badge_marker,
137+
)))
128138
for package in packages:
129139
print('-', package)
130140
print()

0 commit comments

Comments
 (0)