version
Skill4 starsChanged 3 months agoApache-2.0View on GitHub
Bump the root package.json version via scripts/bump-version.mjs, summarize every commit since the last release into a new CHANGELOG.md section, and commit with a `vX.Y.Z` message. Use when cutting a release.
- Deletes or force-pushes
- Commits and pushes
2 other projects use a version of this.
Adopted by
Most recently taken up by
- buildomator/buildomatortheir own version, first seen Sep 20, 2026
- robmclarty/trellistheir own version, first seen Mar 15, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- buildomator/buildomator★ 90same name
- robmclarty/trellis★ 2same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 2 are distinctive, and 9 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
9
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 32
Parse the bump-result JSON from preflight: Read the mode field and branch:
- Very specific: line 37
If since is a SHA: git log <since>..HEAD --no-merges --pretty=format:'%h %s'
- Very specific: line 38
If since is null: git log --no-merges --pretty=format:'%h %s' (initial release)
- Very specific: line 40
Draft the CHANGELOG section: Use the JSON's new field for the version heading (don't recompute):
- Distinctive: line 62
Write for a reader who didn't follow the work.
- Very specific: line 63
If the JSON's since is null, this is the first release — title the section "vX.Y.Z — initial release" instead of listing every commit in …
- Very specific: line 67
Prepend the new section to
CHANGELOG.md: If the file exists, prepend above the existing content (keep a single # Changelog heading at the … - Very specific: line 83
Commit: Use the JSON's new field literally:
- Very specific: line 89
No prefix, no body, no footer, so the release commit reads as vX.Y.Z in the log.
- Distinctive: line 93
If it exits non-zero:
- Very specific: line 98
Create an annotated tag and push it: Use the JSON's new field literally:
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
version
Bump the version in the root package.json, prepend a CHANGELOG.md section summarizing every commit since the last release, and commit. The deterministic work — dirty-tree check, semver math, file rewrite — happens in scripts/bump-version.mjs before this skill begins reasoning. The skill itself only summarizes commits, drafts prose, and runs git.
The repo is one package with one manifest, so a bump rewrites exactly one version field: the root package.json.
Arguments
$ARGUMENTS — one of major, minor, or patch. No default; fail fast if missing or anything else.
Preflight context
- Bump result: !
node scripts/bump-version.mjs $ARGUMENTS
The bump script runs first, before the skill reasons about anything. By the time you read this, one of two things is true on disk:
- the root
package.jsonversion has been rewritten to the new version (mode: "bump"), - nothing was changed and the script emitted an error JSON (
mode: "error").
On a successful bump, the JSON carries everything the skill needs: new is the authoritative version (never recompute it), and since is the SHA of the previous release — the commit the most recent vX.Y.Z git tag reachable from HEAD points at — the left boundary for the CHANGELOG commit range. If since is null, there is no prior release and this is an initial release.
Steps
- Parse the bump-result JSON from preflight. Read the
modefield and branch:mode: "error"→ go to "Steps — error". Do not proceed.mode: "bump"→ continue below.
- Fetch the commit range using the JSON's
sinceSHA:- If
sinceis a SHA:git log <since>..HEAD --no-merges --pretty=format:'%h %s' - If
sinceisnull:git log --no-merges --pretty=format:'%h %s'(initial release)
- If
Draft the CHANGELOG section. Use the JSON's
newfield for the version heading (don't recompute):## vX.Y.Z — YYYY-MM-DD ### Added - <one line per user-visible addition> ### Changed - <behavior changes, refactors that matter externally> ### Fixed - <bug fixes> ### Internal - <tooling, tests, docs — keep this section short or omit>Rules for the summary:
- Group by impact, not by commit. Collapse three commits that together land one feature into one bullet.
- Omit any
Added/Changed/Fixed/Internalsection that has no entries. - Each bullet is one line. Reference commit hashes only if the line is genuinely ambiguous without one.
- Write for a reader who didn't follow the work. "Fixed flaky cache eviction under concurrent writes" beats "fixed bug in cache".
- If the JSON's
sinceisnull, this is the first release — title the section "vX.Y.Z — initial release" instead of listing every commit in repo history.
Print the drafted section back to the user as a fenced
markdowncode block in your response text — the entire block, verbatim, exactly as it will be prepended toCHANGELOG.md. This is the user's one chance to see the prose in isolation before it's folded into the file, committed, and tagged. Do this before moving on to step 4; don't summarize or abbreviate — print the raw markdown. The skill continues automatically after printing (no wait for confirmation); if the user wants to change the prose, they'll interrupt.Prepend the new section to
CHANGELOG.md. If the file exists, prepend above the existing content (keep a single# Changelogheading at the very top). If it doesn't exist, create it with:# Changelog <new section here>Stage exactly
package.json+CHANGELOG.md, nothing else:git add package.json CHANGELOG.mdConfirm via
git status --shortthat no other files are staged. If anything unexpected is staged, stop and hand it back to the user — a release commit is not the place to sneak other changes in.Commit. Use the JSON's
newfield literally:git commit -m "vX.Y.Z"No prefix, no body, no footer, so the release commit reads as
vX.Y.Zin the log. The authoritative release marker is the annotated tag created in step 8; the next bump finds "the last release" from that tag (the plain commit message is only a fallback).Verify with
pnpm check --only docs,links,spell,prose,prose-health --bail. Only these five checks can fail on a(version string + CHANGELOG)diff — a single semver-string replacement plus prose can't break types, lint, struct, deps, dead-code, or tests, so running the full pipeline is wasted CPU. The two prose slots are in the set because vale and the prose ratchet readCHANGELOG.mdlike any other markdown; the v0.12.6 release shipped a two-semicolon sentence that passed the olddocs,links,spellset locally and then failedproseinpublish.yaml, stranding the tag on a commit that can never pass. The heavy checks gateprepublishOnly(check:all) instead, which is where release-readiness actually matters. If the narrow check exits 0, continue to step 8.If it exits non-zero:
- The release commit is already created (step 6 already ran).
- Undo with
git reset --hard HEAD~1. This restores bothpackage.json(back to the old version) andCHANGELOG.md. - Tell the user the check failed, show the tail of the relevant
.check/*.txtor.check/*.jsondiagnostic, and stop. Don't retry the commit; the user decides whether to fix and re-invoke the skill or investigate first.
Create an annotated tag and push it. Use the JSON's
newfield literally:git tag -a vX.Y.Z -m "vX.Y.Z" git push origin vX.Y.ZAnnotated (not lightweight) so the tag carries author, date, and message. Pushing the tag triggers the release pipeline:
publish.yamlstarts an OIDC trusted-publishing run that pauses at thenpm-publishenvironment for a required-reviewer approval, andrelease.yamlcreates the GitHub Release from the CHANGELOG section. Pushingrefs/tags/vX.Y.Zalso sends the commit it points to, so the tagged commit reaches the remote even if the branch ref hasn't moved yet. The push is tag-only by design — branch pushes stay the user's call — but that means the branch ref lags until they push it (see step 9).Error handling:
git tagfails because the tag already exists → stop and tell the user. Don't force-overwrite. A prior release at this version already exists and the user needs to resolve it by hand.git pushfails (network, auth, permissions) → the local tag is already created. Tell the user the commit + tag exist locally, show the push error, and suggest re-runninggit push origin vX.Y.Zonce the issue is resolved. Do not delete the tag.
- Report back. Tell the user: the old version, the new version (both from the JSON), the commit SHA, the tag name, the number of commits summarized, and whether the tag push succeeded. Then point them at the two things that finish the release: (a) approve the paused
publish.yamlrun in GitHub Actions (thenpm-publishgate) to let the provenance publish proceed, and (b) push the release branch (git push origin main) so the branch ref includes the release commit — the skill pushes only the tag.
Steps — error
Triggered when the preflight JSON's mode is "error". The script made no changes (no version field touched, no commit). Branch on error_type:
dirty_tree→ tell the user the working tree must be clean before a release commit; show the listed dirty files; suggest committing or stashing first; stop.usage→ relay the script's usage message verbatim; stop.runtime→ relay the script's message and stop. Don't speculate or retry.
In every error case: no edits, no git operations, no retry. The user decides what to do next.
When to use this skill
- Cutting a release, even an internal one (
patch/minor/major). - User asks to "bump the version" or "tag a new version".
When NOT to use this skill
- There's no meaningful change since the last release (no commits between last tag and HEAD). Tell the user and stop.
- The user wants to edit an existing CHANGELOG entry or retro-tag an older commit — that's a different workflow, not this skill.
Edge cases
- No prior release. When
sincein the JSON isnull, treat the entire history as the range and title the sectionvX.Y.Z — initial release. The script identifies the previous release from the most recentvX.Y.Zgit tag reachable from HEAD (resolved to its commit), falling back to a commit messaged exactlyvX.Y.Zonly when no release tag exists — so a release cut by direct-tagging (rather than through this skill) is still detected correctly. CHANGELOG.mdexists but has no# Changelogheading. Prepend the new heading plus the new section; leave the old content below untouched.- Commit list contains merge commits. Drop them from the summary unless they introduced something not present in the squashed commits.
--no-mergeson the log is fine if the output is noisy. - A commit is marked with
BREAKING:or!:but the user asked forpatchorminor. Warn the user and ask if they meantmajor. Don't override silently. Note: by this point the bump has already happened on disk (the script ran in preflight); if the user wantsmajorinstead, they need togit restore package.jsonand re-invoke/version major. pnpm check --only docs,links,spell,prose,prose-health --bailfails in step 7.git reset --hard HEAD~1restores the pre-bump state. Do not amend, do not retry the commit from inside the skill — the user decides. Common causes: a word in the new CHANGELOG entry is missing fromcspell.json'swordslist, or a vale rule rejects a sentence (e.g.Repo.Semicolonon more than one semicolon). Fix via a separate commit, then re-invoke/version.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

