Skip to content

ci: release crates from a release tag - #524

Merged
nlopes merged 2 commits into
mainfrom
ci/automatic-releases
Nov 28, 2026
Merged

nlopes merged 2 commits into
mainfrom
ci/automatic-releases

Conversation

@nlopes

@nlopes nlopes commented Nov 27, 2026 •

Copy link
Copy Markdown
Owner

Releases acdc-cli, acdc-lsp, acdc-mcp and acdc-editor-wasm from a release tag, with one hand-written workflow.

How to release

  1. Bump the crates and move their [Unreleased] entries into ## [X.Y.Z] - YYYY-MM-DD, then push to main.
  2. Tag a commit on main and push the tag:
    git tag release-YYYY-MM-DD <commit>
    git push origin release-YYYY-MM-DD

release.yml then releases every one of those crates whose <crate>-vX.Y.Z tag doesn't exist yet. acdc-parser isn't part of it; it's still published by hand.

What release.yml does

  • ci, tck: the full CI (ci.yml with every path filter on) and the TCK, on the tagged commit.
  • plan:
    • fails if the tag isn't on main, or if there's nothing to release;
    • fails if a bumped version has no changelog section;
    • fails if git ls-remote errors, instead of releasing everything.
  • build: runs alongside CI, building each crate for five targets with taiki-e/upload-rust-binary-action:
    • macOS ARM64 and x86-64, Linux ARM64 and x86-64 (glibc 2.35), and Windows x86-64 on VS 2022;
    • all features, fat LTO;
    • checks that each binary starts.
  • wasm: the wasm-pack tarball.
  • publish: per crate, once CI, TCK and all of that crate's builds pass.
    • It checks that every archive and .sha256 is present and intact.
    • It runs gh release create <crate>-vX.Y.Z --target <sha> with notes from the crate's changelog.
    • A crate whose build failed doesn't block the others.

Pull requests and pushes to main that change release.yml run all of this as a dry run: everything builds, and publish prints the gh release create command instead of running it.

Archives are <crate>-<target>.tar.gz (.zip on Windows) with <crate>-<target>.sha256. Each unpacks to <crate>-<target>/ with the binary, LICENSE, the README and CHANGELOG.md; the CLI also ships the two font licenses.

Also in this PR

  • release-cli.yml, release-lsp.yml and release-editor-wasm.yml are replaced.
  • The CLI tests also run on Windows and macOS, since release builds don't run tests.
  • Two CLI test fixes:
    • json_output only pipes stdin when it parses from stdin, which fixes a broken-pipe flake.
    • The missing-input test compares errors across miette's line wraps, which the longer Windows error triggers.

The first release tag ships acdc-mcp-v0.1.0. The cli 0.3.0, lsp 0.3.0 and wasm 0.6.0 tags already exist, so those crates ship at their next bump.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Y3gNNefj3Dtn8WRLNzapGr

@nlopes nlopes changed the title ci: publish releases automatically on version bumps ci: release automatically on version bumps with dist Nov 27, 2026
json_output only pipes stdin when the input is `-`, so the child can't
exit before the write and fail with a broken pipe. The missing-input test
compares errors after joining miette's wrapped lines, which wrap the
longer Windows OS error.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y3gNNefj3Dtn8WRLNzapGr
@nlopes
nlopes force-pushed the ci/automatic-releases branch from 003bd27 to e7b26dd Compare November 28, 2026 12:33
Pushing a `release-*` tag on a commit on main releases every crate
(acdc-cli, acdc-lsp, acdc-mcp, acdc-editor-wasm) whose `<crate>-vX.Y.Z`
tag doesn't exist yet. release.yml runs the full CI and TCK on that
commit, builds each crate for five targets with
taiki-e/upload-rust-binary-action, and publishes each crate's GitHub
release, with notes from its changelog, once CI, TCK and all of its
builds pass. Changes to release.yml build everything without publishing.

This replaces release-cli.yml, release-lsp.yml and release-editor-wasm.yml.
The CLI tests also run on Windows and macOS now, since release builds
don't run tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y3gNNefj3Dtn8WRLNzapGr
@nlopes
nlopes force-pushed the ci/automatic-releases branch from e7b26dd to 889c90c Compare November 28, 2026 12:40
@nlopes nlopes changed the title ci: release automatically on version bumps with dist ci: release crates from a release tag Nov 28, 2026
@nlopes
nlopes merged commit 451b025 into main Nov 28, 2026
57 checks passed
@nlopes
nlopes deleted the ci/automatic-releases branch November 28, 2026 13:15
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