Bump antsibull-changelog, and output MarkDown version next to RST version of changelog.

pull/82681/head
Felix Fontein 4 months ago
parent b8b12c4be3
commit 746ecb544a

@ -1,5 +1,6 @@
include COPYING include COPYING
include bin/* include bin/*
include changelogs/CHANGELOG*.md
include changelogs/CHANGELOG*.rst include changelogs/CHANGELOG*.rst
include changelogs/changelog.yaml include changelogs/changelog.yaml
include licenses/*.txt include licenses/*.txt

@ -1,8 +1,8 @@
Changelogs Changelogs
========== ==========
As part of the release process a version-specific `CHANGELOG-vX.Y.rst` will be generated from fragments in As part of the release process a version-specific `CHANGELOG-vX.Y.rst` and `CHANGELOG-vX.Y.md` will be generated from
the `fragments` directory. fragments in the `fragments` directory.
On release branches once a release has been created, consult the branch's version-specific file for changes that have On release branches once a release has been created, consult the branch's version-specific file for changes that have
occurred in that branch. The `devel` branch does not have a generated changelog, only changelog fragments. occurred in that branch. The `devel` branch does not have a generated changelog, only changelog fragments.

@ -11,6 +11,9 @@ mention_ancestor: false
notesdir: fragments notesdir: fragments
prelude_section_name: release_summary prelude_section_name: release_summary
new_plugins_after_name: removed_features new_plugins_after_name: removed_features
output_formats:
- md
- rst
sections: sections:
- ['major_changes', 'Major Changes'] - ['major_changes', 'Major Changes']
- ['minor_changes', 'Minor Changes'] - ['minor_changes', 'Minor Changes']

@ -973,7 +973,7 @@ def create_github_release_notes(upstream: Remote, repository: str, version: Vers
variables = dict( variables = dict(
version=version, version=version,
releases=get_release_artifact_details(repository, version, validate), releases=get_release_artifact_details(repository, version, validate),
changelog=f"https://github.com/{upstream.user}/{upstream.repo}/blob/v{version}/changelogs/CHANGELOG-v{version.major}.{version.minor}.rst", changelog=f"https://github.com/{upstream.user}/{upstream.repo}/blob/v{version}/changelogs/CHANGELOG-v{version.major}.{version.minor}.md",
) )
release_notes = template.render(**variables).strip() release_notes = template.render(**variables).strip()
@ -1094,7 +1094,7 @@ This release is a maintenance release containing numerous bugfixes.
{% endif %} {% endif %}
The full changelog can be found here: The full changelog can be found here:
https://github.com/{{ upstream.user }}/{{ upstream.repo }}/blob/v{{ version }}/changelogs/CHANGELOG-v{{ info.short }}.rst https://github.com/{{ upstream.user }}/{{ upstream.repo }}/blob/v{{ version }}/changelogs/CHANGELOG-v{{ info.short }}.md
Schedule for future releases Schedule for future releases

@ -161,9 +161,13 @@ def main() -> None:
# Make sure a changelog exists for this version when testing from devel. # Make sure a changelog exists for this version when testing from devel.
# When testing from a stable branch the changelog will already exist. # When testing from a stable branch the changelog will already exist.
major_minor_version = '.'.join(__version__.split('.')[:2]) major_minor_version = '.'.join(__version__.split('.')[:2])
changelog_path = f'changelogs/CHANGELOG-v{major_minor_version}.rst' changelog_paths = [
pathlib.Path(clean_repo_dir, changelog_path).touch() f'changelogs/CHANGELOG-v{major_minor_version}.rst',
complete_file_list.append(changelog_path) f'changelogs/CHANGELOG-v{major_minor_version}.md',
]
for changelog_path in changelog_paths:
pathlib.Path(clean_repo_dir, changelog_path).touch()
complete_file_list.append(changelog_path)
expected_sdist_files = collect_sdist_files(complete_file_list) expected_sdist_files = collect_sdist_files(complete_file_list)
expected_wheel_files = collect_wheel_files(complete_file_list) expected_wheel_files = collect_wheel_files(complete_file_list)

Loading…
Cancel
Save