From 0e06d46740009d0c39564ece1e5b09a0403d2f6f Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Thu, 5 Nov 2026 16:28:38 +0100 Subject: ci: use the changelog section as the release notes Readers see what changed on the download page, with no trip to another document. A tag without a changelog section now fails instead of publishing empty notes. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/deploy_github_releases.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/deploy_github_releases.yml b/.github/workflows/deploy_github_releases.yml index f78687d1..4c0c7bd9 100644 --- a/.github/workflows/deploy_github_releases.yml +++ b/.github/workflows/deploy_github_releases.yml @@ -37,5 +37,8 @@ jobs: apk="HardenedPass_${TAG}.apk" cp app/build/outputs/apk/release/app-release.apk "$apk" sha256sum "$apk" > "$apk.sha256" - gh release create "$TAG" "$apk" "$apk.sha256" --draft --title "$TAG" \ - --notes "See [CHANGELOG.md](https://github.com/${GITHUB_REPOSITORY}/blob/${TAG}/CHANGELOG.md)." + # The release notes are this version's section of the changelog. + awk -v head="## [${TAG#v}]" 'index($0, head) == 1 { found = 1; next } /^## \[/ { found = 0 } found' \ + CHANGELOG.md > notes.md + grep -q '[^[:space:]]' notes.md || { echo "No CHANGELOG.md section for $TAG"; exit 1; } + gh release create "$TAG" "$apk" "$apk.sha256" --draft --title "$TAG" --notes-file notes.md -- cgit v1.2.3