feat(ci): publish versioned releases with CalVer tags #2
merged
cole.christensen@gmail.com wants to merge
ci/calver-release-publishing
into main
No CI
Summary
- Publishes versioned runner binaries as release assets using CalVer tags (
YYYY.MM.BUILD) - Adapted from the alacritty-minecraft versioning pattern
- CI artifacts remain unversioned (per-run already)
Changes
- src/config.rs: Read
ANVIL_SERVER_URLandANVIL_TOKENfrom env vars, so CI can authenticate without a config file - src/commands/release.rs: Add
--format jsontoanvil release listfor script consumption - ci/release.sh: Compute next CalVer version — reads latest release tag, increments build within same month, resets to 1 on new month
- .anvil.yml
build-runner: On main branch pushes, run release.sh, create release, upload both architectures as versioned assets
Asset naming
- Release assets:
anvil_runner_linux_amd64_2026.04.1,anvil_runner_linux_arm64_2026.04.1 - CI artifacts (unchanged):
anvil_runner_linux_amd64,anvil_runner_linux_arm64
Prerequisite
Before merging, set the CI secret:
``` anvil ci set-secret ANVIL_TOKEN fangorn/anvil-cli ```
Without this, the main-branch publish will fail loudly.
Test plan
- Local: built both architectures in rust:1.86-bookworm arm64 container
- Local: verified release.sh default (no releases → YYYY.MM.1)
- Local: verified release.sh increment (existing YYYY.MM.N → YYYY.MM.N+1)
- Local: verified release.sh new-month reset (existing YYYY.MM-1.N → YYYY.MM.1)
- Local: verified –format json output parses with jq
- CI: set ANVIL_TOKEN secret, verify full pipeline publishes a release
Created Apr 10, 2026 at 05:38 UTC
| Merged Apr 10, 2026 at 21:04 UTC
by
cole.christensen@gmail.com