agentleFS
ralphkraussralphkrauss/agent-orchestrator/.claude/skills/publish-release/SKILL.md

publish-release

Skill4 starsChanged 7 months agoMITView on GitHub

Publish this npm package through the tag-triggered release workflow with changelog-backed GitHub Release notes. Use when user says "publish release", "publish npm package", "npm release", "create release", or wants to ship a new package version.

  • Installs packages
  • Commits and pushes

5 other projects use a version of this.

Adopted by

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

16 rules. 0 are common, 9 are distinctive, and 7 are very specific to this project.

  • 0

    Common

    Most of the 5 edited versions we read keep these.

  • 9

    Distinctive

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Very specific:

    Read PUBLISHING.md first for the authoritative release contract.

    line 12
  2. Distinctive:

    Check the current branch, local status, recent commits, npm package version, npm dist-tags, and existing git tags.

    line 28
  3. Distinctive:

    If unrelated local changes exist, commit only the release-related changes or ask how they should be handled.

    line 31
  4. Very specific:

    Update CHANGELOG.md before running npm version:

    line 36
  5. Very specific:

    keep an empty ## Unreleased heading at the top.

    line 38
  6. Very specific:

    add ## <version> - YYYY-MM-DD for the version being released.

    line 39
  7. Distinctive:

    Run the changelog extraction script for the intended version and verify it prints the notes that should appear on the GitHub Release:

    line 44
  8. Distinctive:

    Run the release gate:

    line 53
  9. Distinctive:

    Do not continue if verification fails.

    line 60
  10. Very specific:

    Use npm's version command so package.json, pnpm-lock.yaml, the release commit, and the git tag stay aligned:

    line 64
  11. Very specific:

    Use minor, major, or prerelease --preid beta when that matches the release intent.

    line 71
  12. Very specific:

    verify the tag matches package.json.

    line 84
  13. Distinctive:

    create or update the GitHub Release for the same tag.

    line 87
  14. Distinctive:

    After the workflow completes, check:

    line 91
  15. Distinctive:

    Do not publish from a dirty or unverified tree.

    line 103
  16. Distinctive:

    Do not force-push or reuse npm versions.

    line 104

“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md
<!-- Generated from .agents/ by scripts/sync-ai-workspace.mjs. Do not edit directly. -->

Publish Release

Publish this package with npm Trusted Publishing and a matching GitHub Release.

Read PUBLISHING.md first for the authoritative release contract.

Instructions

Step 1: Confirm Release Intent

Confirm the user explicitly asked to publish or prepare a release. Do not publish, tag, deprecate, or push release refs from a vague request.

Identify whether the release should be:

  • stable: publishes to npm latest and creates a normal GitHub Release;
  • prerelease: publishes to npm next and creates a GitHub prerelease.

Step 2: Inspect Repository State

Check the current branch, local status, recent commits, npm package version, npm dist-tags, and existing git tags. Pull the latest target branch before tagging.

If unrelated local changes exist, commit only the release-related changes or ask how they should be handled. Never discard user-owned work.

Step 3: Prepare Release Notes

Update CHANGELOG.md before running npm version:

  • keep an empty ## Unreleased heading at the top;
  • add ## <version> - YYYY-MM-DD for the version being released;
  • move the release content under that exact version heading;
  • include user-facing release notes for features, fixes, breaking changes, migrations, and operational changes.

Run the changelog extraction script for the intended version and verify it prints the notes that should appear on the GitHub Release:

node scripts/extract-changelog-release-notes.mjs <version>

Step 4: Verify The Package

Run the release gate:

pnpm install --frozen-lockfile
pnpm verify

Do not continue if verification fails.

Step 5: Create The Version Commit And Tag

Use npm's version command so package.json, pnpm-lock.yaml, the release commit, and the git tag stay aligned:

npm version patch

Use minor, major, or prerelease --preid beta when that matches the release intent.

Step 6: Push And Monitor

Push the branch and tag together:

git push origin main --follow-tags

Monitor the Publish npm workflow. It must:

  • verify the tag matches package.json;
  • publish to npm with the correct dist-tag, or skip if already published;
  • extract release notes from CHANGELOG.md;
  • create or update the GitHub Release for the same tag.

Step 7: Confirm The Published Release

After the workflow completes, check:

  • npm reports the expected version on latest or next;
  • the GitHub Release exists for the same tag;
  • release notes match the changelog section;
  • a quick installed-package smoke test works when appropriate.

Critical Rules

  • Git tags are the release trigger and source of truth.
  • GitHub Releases are created by the tag workflow, not manually before tagging.
  • Release notes come from CHANGELOG.md, not from ad hoc workflow text.
  • Do not publish from a dirty or unverified tree.
  • Do not force-push or reuse npm versions.

Checklist

  • Read PUBLISHING.md
  • Confirmed stable vs prerelease intent
  • Pulled the latest target branch
  • Updated CHANGELOG.md with the exact version heading
  • Checked extracted release notes
  • Ran pnpm install --frozen-lockfile
  • Ran pnpm verify
  • Ran the correct npm version command
  • Pushed main and tags together
  • Confirmed npm package and GitHub Release are in sync

Reference

  • PUBLISHING.md -- release process and npm Trusted Publishing setup
  • CHANGELOG.md -- release note source for npm and GitHub releases
  • .github/workflows/publish-npm.yml -- tag-triggered npm and GitHub Release workflow
  • scripts/extract-changelog-release-notes.mjs -- release note extraction script

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.