Ignore some changes and group documentation changes into their own section (#4125)

This commit is contained in:
Bruno Alla 2023-02-05 10:03:22 +00:00 committed by GitHub
parent 170cd6fe18
commit 1f65656daf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -82,14 +82,20 @@ def group_pulls_by_change_type(
grouped_pulls = { grouped_pulls = {
"Changed": [], "Changed": [],
"Fixed": [], "Fixed": [],
"Documentation": [],
"Updated": [], "Updated": [],
} }
for pull in pull_requests_list: for pull in pull_requests_list:
label_names = {label.name for label in pull.labels} label_names = {label.name for label in pull.labels}
if "project infrastructure" in label_names:
# Don't mention it in the changelog
continue
if "update" in label_names: if "update" in label_names:
group_name = "Updated" group_name = "Updated"
elif "bug" in label_names: elif "bug" in label_names:
group_name = "Fixed" group_name = "Fixed"
elif "docs" in label_names:
group_name = "Documentation"
else: else:
group_name = "Changed" group_name = "Changed"
grouped_pulls[group_name].append(pull) grouped_pulls[group_name].append(pull)