Skip to content

Release the CLI when a version bump merges to main - #30

Merged
mzupan merged 1 commit into
mainfrom
ci/release-on-merge
Nov 8, 2026
Merged

mzupan merged 1 commit into
mainfrom
ci/release-on-merge

Conversation

@mzupan

@mzupan mzupan commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

Makes the CLI release the way query-api does, and stops the security workflow running on merges to main.

Release on merge

release.yml now runs on pushes to main that change Cargo.toml, and by hand (workflow_dispatch), instead of on pushed tags.

  • validate reads the version from Cargo.toml.
    • If v<version> is already tagged on another commit, the run skips the release and says so in the summary. Dependabot changes Cargo.toml without a version bump, so these merges shouldn't fail.
    • Otherwise it runs the tests and pushes the tag. If the tag is already on this commit, it's a re-run of a failed release and continues.
  • build and release are unchanged apart from taking the tag from validate.

The README's release section now describes bump → PR → merge.

Security workflow

security.yml no longer runs on push: main. It still runs on pull requests, weekly, and by hand.

After merging

v0.2.0 (#29) is already on main without a tag. This PR doesn't touch Cargo.toml, so merging it won't start a release. Run gh workflow run release.yml --ref main once to publish v0.2.0.

Checks

actionlint is clean for the changed lines. It still flags the existing macos-15-intel runner label, which its version doesn't know.

Like query-api, merging a Cargo.toml version bump now tags and publishes
that version; tags are no longer pushed by hand. A Cargo.toml change that
keeps a released version (dependabot) publishes nothing. The security
workflow no longer runs on pushes to main.
@mzupan
mzupan merged commit 1b7a10b into main Nov 8, 2026
5 checks passed
@mzupan
mzupan deleted the ci/release-on-merge branch November 8, 2026 17:42
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