Skip to content

Write HTML. Render video. Built for agents.

fix(release): annotate version tag + correct release push instructions (#1517)

Vance Ingallsca3cab340baa
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 2a4b200c4d..307c3cc2b9 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -140,11 +140,16 @@ All packages use **fixed versioning** — every release bumps all packages to th
```bash
bun run release:prepare 0.2.0 # drafts changelog if needed, then creates the release commit/tag after review
-git push origin main --tags # triggers the publish workflow
+git push origin main # push the release commit
+git push origin v0.2.0 # push the tag → triggers the publish workflow
```
+> Push the **specific tag**, not `git push --tags` — the latter pushes every local tag and the whole push is rejected if any one already exists on the remote.
+
The `release:prepare` script drafts missing release notes on the first run and stops for manual review. After the generated TODO summary is rewritten, rerun the same command; it delegates to `set-version`, which creates a `chore: release v<version>` commit and a `v<version>` git tag. Pushing the tag triggers CI to publish all packages to npm and create a GitHub Release.
+`set-version` also refuses to tag if a **higher** semver tag already exists (a stale higher tag would hijack tag-sorting installers like `npx skills`). Delete the stray tag (`git tag -d <tag> && git push origin :refs/tags/<tag>`) or, only if intentional, pass `--skip-monotonicity-check`.
+
### Pre-releases (alpha / beta / rc)
Use a pre-release suffix to publish to a named npm dist-tag instead of `latest`:
diff --git a/scripts/set-version.ts b/scripts/set-version.ts
index eae35d79fa..0241626a6d 100644
--- a/scripts/set-version.ts
+++ b/scripts/set-version.ts
@@ -130,7 +130,13 @@ function createReleaseCommitAndTag(version: string, skipMonotonicityCheck: boole
cwd: ROOT,
stdio: "inherit",
});
- execFileSync("git", ["tag", `v${version}`], { cwd: ROOT, stdio: "inherit" });
+ // Annotated tag (-a -m): works regardless of a contributor's git config; a
+ // lightweight `git tag` fails ("no tag message?") when tag.forceSignAnnotated
+ // or similar is set globally.
+ execFileSync("git", ["tag", "-a", `v${version}`, "-m", `v${version}`], {
+ cwd: ROOT,
+ stdio: "inherit",
+ });
console.log(`\nCreated commit and tag v${version}`);
}