Skip to content

Auto-cut Arduino releases on merge to main#751

Merged
bwhitman merged 1 commit into
mainfrom
claude/hopeful-lumiere-efeaf5
Jun 22, 2026
Merged

Auto-cut Arduino releases on merge to main#751
bwhitman merged 1 commit into
mainfrom
claude/hopeful-lumiere-efeaf5

Conversation

@bwhitman

Copy link
Copy Markdown
Collaborator

Cuts a GitHub release on every merge to main (the Arduino Library Manager polls releases and picks each one up), so releasing no longer needs manual steps.

What release.yml does, per merge to main

  1. Reads version= from library.properties and computes the next patch (1.2.7 → 1.2.8), skipping any tag that already exists.
  2. Opens a one-line bump-X PR and merges it. The bump can't be pushed straight to main — it's a protected branch (PR required, enforce_admins on) — so this mirrors the manual claude/bump-* flow used for every release to date.
  3. Creates the GitHub release with a plain tag (1.2.8, no v — Arduino requires this format).
  4. Dispatches the existing godot-addon.yml at the new tag so amy-godot-addon.zip still attaches.

Design notes

  • Fully GITHUB_TOKEN-based, no PAT. A GITHUB_TOKEN-created tag can't fire godot-addon.yml's push: tags trigger, but workflow_dispatch is the one event GITHUB_TOKEN can trigger — so we dispatch the Godot build at the tag (its run sees github.ref=refs/tags/<ver> and attaches the zip). Nothing to renew.
  • Can't loop. Pushes/merges made with GITHUB_TOKEN don't re-trigger workflows, so the bump merge can't re-fire this workflow. A [skip release] marker on the merge commit + the job if: are belt-and-suspenders.
  • Serialized (concurrency: release) so two quick merges can't collide on a version.

Prerequisite (already done)

Requires the org-level "Allow GitHub Actions to create and approve pull requests" setting, now enabled for shorepine.

Heads-up

Merging this PR is itself a merge to main, so it will immediately cut 1.2.8 as the first auto-release. To skip a release for any future merge, put [skip release] in the merge commit message.

🤖 Generated with Claude Code

release.yml cuts a patch release on every merge to main: it bumps
library.properties via an auto-opened-and-merged bump PR (main is
protected, so the bump can't be pushed directly), creates the plain-tag
GitHub release the Arduino Library Manager picks up, then dispatches the
Godot addon build at the new tag to attach amy-godot-addon.zip.

Fully GITHUB_TOKEN-based, no PAT: workflow_dispatch is the one event the
built-in token can trigger, so the Godot zip still attaches without
needing a PAT-pushed tag. GITHUB_TOKEN merges don't re-trigger workflows,
so the bump merge can't loop; a [skip release] marker is belt-and-suspenders.

Requires the org-level "Allow GitHub Actions to create and approve pull
requests" setting (now enabled for shorepine).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@bwhitman bwhitman merged commit fd14f45 into main Jun 22, 2026
8 checks passed
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.

1 participant