[IMPROVEMENT] ci: add manual checksum workflow for release artifacts#2277
Open
x15sr71 wants to merge 1 commit into
Open
[IMPROVEMENT] ci: add manual checksum workflow for release artifacts#2277x15sr71 wants to merge 1 commit into
x15sr71 wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In raising this pull request, I confirm the following (please check boxes):
Reason for this PR:
Sanity check:
Repro instructions:
This is a CI-only change — no runtime code modified, no binary behavior changed. No changelog entry added. Verification is the workflow run linked below.
What this PR does
Adds
.github/workflows/create_release_checksums.yml— a manualworkflow_dispatchworkflow that validates a release tag, downloads all its assets viagh release download, generateschecksums.sha256viasha256sum * | sort -k2, and uploads it back to the same release.Why this is needed
GitHub Releases expose per-asset SHA256 digests in the release UI, but there is no downloadable
checksums.sha256file that users can verify locally across all artifacts at once. With this PR, after downloading artifacts users can run:and get a pass/fail for every artifact in one step.
Why workflow_dispatch (not automatic)
The repo has 7 release workflows all triggered independently on
release: published(Windows, AppImage ×3, deb ×2, Debian 13 deb ×2, Snap, systemlibs ×2, macOS).needs:only works within the same workflow file — there is no cross-workflow fan-in primitive in GitHub Actions. An automatic trigger would race against the builds and produce a partial manifest.workflow_dispatchmeans the release manager runs this once after confirming all packaging workflows are green. It is safe to rerun —checksums.sha256is removed from the runner before regenerating to prevent self-inclusion.How to trigger
After all packaging workflows complete successfully:
v0.96.6)checksums.sha256is attached to that releaseImplementation notes
gh release download— downloads only GitHub Release assets, not CI artifacts--repo ${{ github.repository }}— fork-safe--skip-existing— idempotent on rerunssort -k2— sorts by filename, conventional checksum formatsoftprops/action-gh-release@v3— same action/version used in all 7 packagingworkflows in this repo
permissions: contents: write— matchesrelease.ymlandbuild_linux_systemlibs.ymlactions/checkout— workflow never touches source codeTesting
Local —
gh release download v0.96.6 --repo CCExtractor/ccextractor, thensha256sum -c checksums.sha256against all 14 assets. All returned OK.CI — fork run 27032822731 via
workflow_dispatchagainstv0.96.6. All 5 steps green (validate → download → sanity check → generate → upload). Fork run used a hardcoded repo reference for testing; PR version uses${{ github.repository }}.Downloaded the generated
checksums.sha256from the fork release and ransha256sum -c checksums.sha256locally against all assets attached tov0.96.6at test time — all returned OK.