Cut a release of the compiler — a release branch, the hand-written release notes entry, the website's release material, then the tag that publishes everything. Use when asked to cut, tag, ship or publish a release, or to rehearse one on a release branch. Invoke as `/release <X.Y.Z>`.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Is that skill safe to install?
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
Are you the author of Release?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/maxon-lang-release)
---
name: release
description: Cut a release of the compiler — a release branch, the hand-written release notes entry, the website's release material, then the tag that publishes everything. Use when asked to cut, tag, ship or publish a release, or to rehearse one on a release branch. Invoke as `/release <X.Y.Z>`.
---
# Cut a release
**`docs/RELEASING.md` IS THE PROCESS AND THIS IS NOT A SECOND COPY OF IT.** Read it. It carries the
whole picture — the bootstrap chain, the second self-compile an emitted-runtime change needs, the platform gotchas, the install
scripts, the package managers, the verification afterwards. This file is the ORDER of operations
and the checks, and it links out for every "why".
⛔ **THE TAG IS THE STEP THAT PUBLISHES.** `release.yml`'s `guard` refuses a tag with no release notes
entry or an unbumped extension before any runner starts, and `publish` runs only after all four
targets have built and natively suite-tested — so a failed target publishes nothing.
## 0 · No rehearsal unless the user asks for one
Go straight to the tag (user ruling): every commit on `main` was already tested by CI, and the tagged
run builds and suite-tests the same four targets before `publish` starts. A failed target publishes
nothing and costs a retry at the same version (§5b), not a broken release.
When the user does ask, a `release/X.Y.Z` branch runs the whole pipeline at the real version with no
tag: `guard` recognises the ref and sets `publish=no`. ⚠ **Pushing the branch does not start it** —
`release.yml` triggers on `v*` tags and `workflow_dispatch` only:
```bash
gh workflow run release.yml --ref release/X.Y.Z
```
`guard`'s release notes and extension checks run only on a tag, so no rehearsal reaches them.
## 1 · Cut the branch
```bash
git checkout -b release/X.Y.Z
```
⛔ **THEN REBUILD, BEFORE ANYTHING ELSE** — `./maxon-bin/.maxon/maxon run build` at the repo root, the
build that stamps a version (`maxon build maxon-bin` is a path build and stamps none). The version comes
from the ref at BUILD time, so a compiler built before the branch existed still reports `dev`, and
§3b's `compiler-version` check refuses it. When the emitted runtime changed since the slot was built,
`run build` builds a second time by itself and prints why.
## 2 · Write the release notes entry, by hand
```bash
scripts/release-notes.sh --commits-since
```
⭐ **THAT LISTING IS REFERENCE MATERIAL, NOT A DRAFT.** A commit subject is written for someone
changing the compiler; the entry is for someone installing it. Rename `## Unreleased` — the breaking changes the
release's commits already recorded — to `## X.Y.Z — YYYY-MM-DD`, or write that heading when the file
has no `## Unreleased`, and add `### Added` / `### Changed` / `### Fixed` / `### Removed` beneath it.
`### Breaking changes` comes first.
**Do not paste commit subjects in**: nearly every one would need rewriting for an installer.
⛔ **EVERY BREAKING CHANGE CARRIES ITS FIX.** A change that can break an existing project, script or
workflow — a removed or renamed spelling, command, flag, file name, syntax or stdlib API, or a program
that is now refused or behaves differently — is a `- ` bullet under `### Breaking changes`, followed by
an indented `Fix: …` line: concrete, short, and checked against the documentation as it stands. Read
`--commits-since` for any such change no commit recorded. `node website/scripts/sync-docs.mjs` fails on a
breaking change without a `Fix:` line, and `scripts/release-notes.sh --section` refuses a file that still
has `## Unreleased`. The compiler reports these entries to a project built with a newer release, so a
vague fix fails that project's author.
⚠ **THE REST OF THE ENTRY STATES WHAT CHANGED.** No install steps, no "click More info", no warnings
about how to use the product. Those belong on the website's installation page and in each archive's
`INSTALL.md`, which already carry them; an instruction elsewhere in the notes is either stale or
duplicated. Only a fix for what the release broke is an instruction.
⛔ **THEN `node website/scripts/sync-docs.mjs`, AND COMMIT THE RESULT.** It rewrites
`maxon-bin/Compiler/BreakingChangesGenerated.maxon` so the compiler lists the new release; the compiler
built at the tag reports from that file, and the preflight fails on a stale one.
## 3 · Write the website's release material
```bash
scripts/announce.sh X.Y.Z
```
Three files under `website/` — the announcement post, the release notes page, and the `RELEASE_VERSION`
the download links are built from. It **commits nothing**.
⛔ **EVERY `### Added` AND `### Changed` ITEM HAS A PAGE THAT DESCRIBES IT.** The tag deploys maxon.dev, and
a feature the release notes announce but no page explains sends its reader nowhere. For each item, find the
section of the `docs/` source that describes the shipped behaviour (`website/MAINTAINING.md`'s map says
which); a missing or false one is written on this branch and synced with
`node website/scripts/sync-docs.mjs`.
Then commit everything the branch carries — the release notes entry, the website material, any page:
```bash
git add -A && git commit -m 'release notes: X.Y.Z'
```
## 3b · Preflight — the checks the tag would otherwise apply
```bash
scripts/release-preflight.sh X.Y.Z
```
⛔ **RUN IT, AND RUN IT AFTER THE REBUILD AND THE COMMIT.** Every check here also runs at the tag, where a
failure costs a re-tag or a release whose links 404. It reads the worktree (`worktree-clean` fails on
anything uncommitted), the copied docs, the extension gate, the release notes entry, shellcheck, CI at this
commit, and the built binary's version. A fix made after it is committed and the preflight run again.
⚠ **SKIPPED IS NOT PASSED.** The summary names every skip; read them rather than the exit code alone.
## 4 · Tag
```bash
git tag -a vX.Y.Z -m 'Maxon vX.Y.Z'
git push origin release/X.Y.Z vX.Y.Z
```
⛔ **THE TAG GOES ON THE FINISHED BRANCH TIP.** Everything downstream reads the repository AT THE TAG
— the maxon.dev post and release notes page, which the release notes link to, take their text from
`RELEASE_NOTES.md` there, and
`website.yml` builds the site from there. A fix committed after the tag is a fix nothing ships.
## 5 · Watch it
`release.yml` builds and natively suite-tests four targets and publishes, then starts the Homebrew,
Docker, VS Code extension, maxon.dev and install-script workflows at the tag — so the download links
go live only once the downloads exist. Check all five actually ran: a release created with `GITHUB_TOKEN`
fires no `release: published`. `install-script` green is what says both one-line installers can
install the new release.
**Report what actually happened**, per job, and read the deploy step's log rather than its exit code:
on a missing credential the maxon.dev deploy SKIPS with a notice and the Homebrew tap with a warning,
and both still report success. (The VS Code extension fails loudly on one instead.)
**Then verify what actually shipped**, which is not the same question as whether the jobs are green:
```bash
scripts/release-postflight.sh X.Y.Z
```
⛔⛔ **DO NOT MERGE BACK UNTIL THIS IS CLEAN.** §6 commits the release's release notes, website material
and extension version to `main`; run it over a release that has to be cut again and `main` carries a
published extension version and a superseded entry, which the NEXT release then trips over.
## 5b · If the release fails — delete the tag, fix on the branch, tag again
**The release has failed** when `release.yml` is red, any workflow it starts is red, or the postflight is
not clean. It is retried **at the same version** (user ruling). `docs/RELEASING.md` has the why of each
step below.
**First, let every run at the tag finish or cancel it** — a deletion under a running `publish` or
`homebrew` races it.
```bash
# 1. The branch the release was cut from. Nothing deletes it before the release succeeds (§6).
git fetch origin --tags --prune
git checkout -B release/X.Y.Z origin/release/X.Y.Z
# 2. The release and its assets, if `publish` got that far.
gh release delete vX.Y.Z --yes
# 3. The tag, with the ruleset lifted for this ONE push.
ruleset="$(gh api repos/maxon-lang/maxon/rulesets --jq '.[] | select(.name == "Release tags") | .id')"
gh api -X PUT "repos/maxon-lang/maxon/rulesets/$ruleset" -f enforcement=disabled
git push origin --delete vX.Y.Z
gh api -X PUT "repos/maxon-lang/maxon/rulesets/$ruleset" -f enforcement=active
gh api "repos/maxon-lang/maxon/rulesets/$ruleset" --jq '.enforcement + " " + ([.rules[].type] | join(","))'
git tag -d vX.Y.Z
```
⛔ **READ THE LAST `gh api` LINE: it must print `active update,deletion,non_fast_forward`.** A protection
left off is worse than the release that needed it lifted.
⚠ **`-B`, never `-b`.** A local `release/X.Y.Z` is already there from the first attempt, so `-b` fails —
and every command after it then runs on `main`. ⛔ If `origin/release/X.Y.Z` is missing, someone deleted
it by hand: push it back from the tag BEFORE step 3, or nothing on origin reaches the release commits
once the tag is gone — `git push origin 'vX.Y.Z^{commit}:refs/heads/release/X.Y.Z'`.
**4. Make the changes on the branch.** A fix already on `main` is cherry-picked. A new fix is written
under the `maxon-coder` skill — invoke it first — and a change to compiler source still owes its case red
then green before it goes on: the tagged run is a battery, not an acceptance. Then, where they apply:
- ⛔ **The VS Code extension, if the failed attempt published it** — its `vscode-extension` run logs
`Published maxon-lang.maxon-lsp-client v<version>`. That version is spent: bump PATCH, with a line in
`vscode-extension/CHANGELOG.md`, or the retry publishes the compiler and then fails on the extension.
- **The release notes entry** gains what the fix changed, and its heading takes the retry's date.
- **The website material**: `announce.sh` refuses an existing post, so remove
`website/src/content/docs/blog/maxon-X-Y-Z.md` and run §3 again.
**5. Then §1's rebuild, §3b's preflight, §4's tag and §5's watch**, exactly as the first time. §6 has not
run — it waits for a clean postflight — so `main` holds nothing of the failed attempt.
## 6 · Merge the tag back, then retire the branch
```bash
git fetch origin --tags --prune
git checkout main && git merge --no-ff vX.Y.Z && git push origin main
tip="$(git rev-parse --verify --quiet origin/release/X.Y.Z)"
if [ -z "$tip" ]; then
echo "origin has no release/X.Y.Z to retire"
elif [ "$tip" = "$(git rev-parse 'vX.Y.Z^{commit}')" ]; then
git push origin --delete release/X.Y.Z && git branch -d release/X.Y.Z
else
echo "release/X.Y.Z has commits past vX.Y.Z: work nothing shipped"
fi
```
⛔ **THE BRANCH IS DELETED HERE AND NOWHERE EARLIER (user ruling).** A clean postflight is the first
point at which the release has succeeded; until then a failure is retried on the branch (§5b). If the
last arm prints, the branch holds work nothing shipped — leave it and tell the user.
⚠ The merge back is not optional — the release notes entry and the website material exist only at the
tag until it happens. The TAG is what is merged rather than the branch, because the tag is exactly what
shipped.
⚠ **Merge, never rebase**, and if `main` moved, build and suite-test the merge before pushing it. A
merge keeps the tag an ancestor of `main`; rebased copies would reappear in the next release's
`--commits-since`.
## 7 · The seed does not move with a release
The seed is the `seed-*` pre-release that `scripts/seed-tag` pins, frozen and independent of releases:
cutting one changes nothing about what builds `main`, and there is nothing to refresh locally. A new seed
is made only when a commit needs one, and that commit lands with it through `land.yml`.
`docs/RELEASING.md` owns the procedure.
## What this skill may not do
- **Never create credentials, accounts or tokens**, and never ask the user to paste a secret. Secrets
are set with `gh secret set`, which prompts and hides the input.
- **Never move a tag with a force-push**, and never delete one except by §5b: the release first, then the
tag with the `Release tags` ruleset lifted for that single push. ⛔ **Never leave the ruleset disabled.**
- **Never delete `release/X.Y.Z` before the release has succeeded** — a clean postflight, §6.
- **Never delete a release that went out clean.** §5b is for a release that failed; one whose postflight
was clean and is later found wanting is superseded by the next patch version.