diff --git a/newsfragments/600.changed.md b/newsfragments/600.changed.md new file mode 100644 index 00000000..baa83c98 --- /dev/null +++ b/newsfragments/600.changed.md @@ -0,0 +1 @@ +Tweak changelog sections ordering. diff --git a/pyproject.toml b/pyproject.toml index ac255435..57a85c21 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -93,13 +93,13 @@ name = "Added" showcontent = true [[tool.towncrier.type]] -directory = "fixed" -name = "Fixed" +directory = "changed" +name = "Changed" showcontent = true [[tool.towncrier.type]] -directory = "changed" -name = "Changed" +directory = "fixed" +name = "Fixed" showcontent = true [[tool.towncrier.type]] diff --git a/scripts/towncrier_to_helm_annotation.py b/scripts/towncrier_to_helm_annotation.py index 8779fa74..669ca113 100755 --- a/scripts/towncrier_to_helm_annotation.py +++ b/scripts/towncrier_to_helm_annotation.py @@ -25,7 +25,7 @@ def find_news_fragments(root_dir): ) ) new_fragments = list({"description": description, "kind": kind} for description, kind in unique_new_fragments) - kind_order = ["security", "deprecated", "added", "fixed", "changed", "removed"] + kind_order = ["security", "deprecated", "added", "changed", "fixed", "removed"] # We order the list by kind and description alphabetically new_fragments.sort(key=lambda x: str(kind_order.index(x["kind"])) + x["description"]) return new_fragments