From 6c53b426bbfa12798139ee22ea557047c70f0b72 Mon Sep 17 00:00:00 2001 From: Anthony Correa Date: Sun, 26 Apr 2026 09:25:22 -0500 Subject: [PATCH] use summary-of-changes in release notes --- .github/workflows/release.yml | 18 ++++++++++++++++-- README.md | 2 ++ 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4d0eb17..208c0a7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -115,6 +115,20 @@ jobs: cd "${RUNNER_TEMP}/mkdocs_out/site_offline/" zip -r "${GITHUB_REF_NAME}.zip" ./${GITHUB_REF_NAME} + - name: Prepare release notes + run: | + set -euo pipefail + + RELEASE_NOTES="${RUNNER_TEMP}/release-notes.md" + + if [[ "${GITHUB_REF_NAME}" == draft* || "${GITHUB_REF_NAME}" == rc* ]]; then + printf 'Prerelease.\n\n' > "${RELEASE_NOTES}" + else + : > "${RELEASE_NOTES}" + fi + + cat docs/summary-of-changes.md >> "${RELEASE_NOTES}" + - name: Publish prerelease if: startsWith(github.ref_name, 'rc') || startsWith(github.ref_name, 'draft') uses: softprops/action-gh-release@v2 @@ -122,8 +136,7 @@ jobs: prerelease: true name: ${{ github.ref_name }} tag_name: ${{ github.ref_name }} - body: | - Prerelease. + body_path: ${{ runner.temp }}/release-notes.md files: | ${{ runner.temp }}/mkdocs_out/site_offline/${{ github.ref_name }}.zip ${{ runner.temp }}/pandoc/${{ github.ref_name }}-${{ env.SHORT_SHA }}.docx @@ -134,6 +147,7 @@ jobs: with: name: ${{ github.ref_name }} tag_name: ${{ github.ref_name }} + body_path: ${{ runner.temp }}/release-notes.md files: | ${{ runner.temp }}/mkdocs_out/site_offline/${{ github.ref_name }}.zip diff --git a/README.md b/README.md index 53298c9..9f319d1 100644 --- a/README.md +++ b/README.md @@ -69,6 +69,8 @@ It builds both the normal site and an offline site package, then publishes based - `rc*`: creates a GitHub prerelease, attaches the offline zip and generated `.docx`, and deploys the preview site to the `gh-pages` branch under `/rc/` - `v*`: creates a GitHub release, attaches the offline zip, and deploys the release site to the root of the `gh-pages` branch +The GitHub release description is generated from `docs/summary-of-changes.md`. Draft and release-candidate prereleases prepend a short prerelease note before that summary. + In all cases, the release workflow uses the same MkDocs configuration in `mkdocs/mkdocs.yml`, with strict mode controlled by the `MKDOCS_STRICT` GitHub Actions variable. ## Project History