Skip to content

Add one-click release workflow to prevent tag/version drift#39

Merged
ejntaylor merged 1 commit into
mainfrom
ci/one-click-release
Jul 13, 2026
Merged

Add one-click release workflow to prevent tag/version drift#39
ejntaylor merged 1 commit into
mainfrom
ci/one-click-release

Conversation

@ejntaylor

Copy link
Copy Markdown
Contributor

Why

The Publish workflow rejected v0.3.3 because the tag (0.3.3) didn't match package.json (0.2.11) — the second time this has happened. Root cause: tags are created by hand, decoupled from the package.json bump, so they can drift from the version that actually gets published.

What

  • .github/workflows/release.yml — a dispatch-driven Release workflow (Actions → Release → Run workflow). Pick patch/minor/major or type an explicit version; it runs npm version to bump + commit + tag, then pushes, publishes to npm (with provenance), and cuts the GitHub release — all from one number. Because the tag is derived from npm version, it can never disagree with package.json.
  • RELEASING.md — documents the one-click path and the manual fallback rules.

The existing publish.yml is untouched: its guard stays as a safety net for hand-made releases, and it won't double-publish (releases created by release.yml use GITHUB_TOKEN, which doesn't re-trigger the release: published event).

Note

This does not itself fix the in-flight v0.3.3 failure — main has diverged from the pulse-protect-node-waf branch that shipped 0.3.00.3.2, so the correct source/version for 0.3.3 needs a human call before re-cutting.

🤖 Generated with Claude Code

Releases were being tagged by hand, decoupled from the package.json
bump, so tags could (and did) disagree with the published version — the
Publish guard rejected v0.3.3 because package.json still said 0.2.11.

Add a dispatch-driven Release workflow that runs npm version to bump,
commit, tag, publish, and cut the GitHub release from one source of
truth, making the tag/version mismatch structurally impossible. Document
the flow (and the manual fallback rules) in RELEASING.md.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@coderbuds

coderbuds Bot commented Jul 13, 2026

Copy link
Copy Markdown

Clear and robust one-click release workflow preventing version drift.

🎯 Quality: 99% Elite · 📦 Size: Medium

📈 This month: Your 215th PR — above team average · Averaging Excellent

See how your team is trending →

@ejntaylor

Copy link
Copy Markdown
Contributor Author

/review

@ejntaylor ejntaylor merged commit ecba65c into main Jul 13, 2026
4 checks passed
@ejntaylor ejntaylor deleted the ci/one-click-release branch July 13, 2026 16:17
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.

2 participants