Skip to content

Gate releases on CI/audit status before tagging#15

Merged
Nathan-D-R merged 2 commits into
mainfrom
fix/gate-publish-on-ci
Jul 19, 2026
Merged

Gate releases on CI/audit status before tagging#15
Nathan-D-R merged 2 commits into
mainfrom
fix/gate-publish-on-ci

Conversation

@Nathan-D-R

Copy link
Copy Markdown
Contributor

Summary

  • publish.yml triggers directly on push: tags: ["v*"] with no dependency on ci.yml or audit.yml passing. GitHub Actions has no way for one workflow file to needs: a job defined in another workflow file, so this has to be enforced before the tag exists rather than inside publish.yml itself.
  • Adds scripts/check-release-ready.sh, which resolves a ref (default HEAD) to a commit SHA and checks the latest ci.yml and audit.yml runs for that SHA via gh run list -w <workflow> -c <sha>. It fails (exit 1, with a message and run URL when available) if a run is missing, hasn't completed, or didn't succeed; it exits 0 with a one-line confirmation only when both are green.
  • Adds RELEASING.md, since there was no written release checklist in this repo. Documents the (single-location) version bump, changelog, commit, and tag/push/publish/verify steps, with the readiness check as an explicit pre-tag step.

Test plan

  • Ran ./scripts/check-release-ready.sh against current main HEAD: correctly reported ci.yml green and audit.yml with no run found for that commit (audit.yml is path-filtered to Cargo.toml/Cargo.lock changes, so this is expected/correct behavior for a docs-only commit), and exited 1.
  • Ran it against 103cb18 (release: v1.2.4, which touched Cargo.toml): both checks passed, exited 0.
  • Ran it against 6086931 (release: v1.2.5): correctly reported ci.yml failed (conclusion=failure) with the run URL, and exited 1.
  • bash -n scripts/check-release-ready.sh (syntax check).

Closes #14

publish.yml triggers on push: tags: ["v*"] with no dependency on ci.yml
or audit.yml passing, and GitHub Actions has no way for one workflow
file to `needs:` a job defined in another, so this has to be enforced
before the tag exists rather than inside publish.yml itself.

Adds scripts/check-release-ready.sh, which resolves a ref to a commit
SHA and checks the latest ci.yml/audit.yml runs for that SHA via
`gh run list -c <sha>`, failing if either hasn't run, hasn't
completed, or didn't succeed. Also adds RELEASING.md, since there was
no written release checklist, with the check as an explicit pre-tag
step.

Closes #14
git rev-parse on an annotated tag returns the tag object's own SHA, not
the commit it points at, so gh run list -c <sha> would never find a
matching run when checking a tag ref (the script's primary intended
use case).
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 18, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
openwraw-docs 2bf872a Jul 18 2026, 10:48 PM

@Nathan-D-R
Nathan-D-R merged commit 02d8afb into main Jul 19, 2026
9 checks passed
@Nathan-D-R
Nathan-D-R deleted the fix/gate-publish-on-ci branch July 19, 2026 00:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Publish workflow isn't gated on CI/audit passing

1 participant