Release gentle-pi through GitHub and npm. Trigger: release, publish, npm publish, GitHub release, version bump.
npx skills add https://github.com/Gentleman-Programming/gentle-pi --skill release
Use this skill when preparing, publishing, or verifying a gentle-pi release.
gentle-pi to npm from a local machine..github/workflows/publish.yml so provenance, environment protection, and registry credentials are controlled by GitHub.main, never from a release tag. Its only caller input is the exact annotated version tag.HEAD; use the freshly fetched origin/main commit and the repository's normal release safeguards. git status --short
git fetch origin main --tags
git log --oneline --decorate --max-count=5 origin/main
package.json to the next semver version. pnpm test
node scripts/verify-package-files.mjs
npm pack --dry-run
npm pack --dry-run verifies package contents and lifecycle scripts without entering a publish path.
git add <intended-files>
git commit -m "<type(scope): release-ready change>"
git push origin HEAD:main
git fetch origin main --tags
version="$(node -p "require('./package.json').version")"
tag="v${version}"
release_sha="$(git rev-parse 'origin/main^{commit}')"
test "$(git rev-parse 'HEAD^{commit}')" = "${release_sha}"
test -z "$(git ls-remote --tags origin "refs/tags/${tag}")"
git tag -a "${tag}" "${release_sha}" -m "gentle-pi ${tag}"
test "$(git rev-parse "${tag}^{commit}")" = "${release_sha}"
git fetch origin main
test "$(git rev-parse 'origin/main^{commit}')" = "${release_sha}"
git push origin "refs/tags/${tag}"
git fetch --no-tags origin "refs/tags/${tag}"
test "$(git rev-parse 'FETCH_HEAD^{commit}')" = "${release_sha}"
gh release create "${tag}" \
--repo Gentleman-Programming/gentle-pi \
--verify-tag \
--title "gentle-pi ${tag}" \
--notes "<release notes>"
Do not retag or overwrite an existing version. The tag target comes from the freshly fetched immutable origin/main commit, not an ambient local branch.
version="$(node -p "require('./package.json').version")"
tag="v${version}"
gh workflow run publish.yml \
--repo Gentleman-Programming/gentle-pi \
--ref main \
-f tag="${tag}"
The workflow definition always comes from protected default main. It accepts only one exact vSemVer tag, fetches the remote annotated tag and current remote main, and requires the peeled tag commit, dispatch/main workflow commit, checkout, and package.json version to match. It re-queries remote tag and main immediately before npm publication, derives the dist-tag internally, and uses trusted OIDC with provenance.
Watch the run and fail the release if it fails:
gh run list --repo Gentleman-Programming/gentle-pi --workflow publish.yml --limit 3
gh run watch <run-id> --repo Gentleman-Programming/gentle-pi --exit-status
npm view gentle-pi@<version> version --registry=https://registry.npmjs.org/
npm dist-tag ls gentle-pi --registry=https://registry.npmjs.org/
npm publish locally. Re-dispatch from trusted main only when the same tag still targets the current remote main and the failure was publication-only.main advances, do not move or recreate the existing tag. Prepare a new release commit/version and create a new annotated version tag. gh run view <run-id> --repo Gentleman-Programming/gentle-pi --log
npm view gentle-pi@<version> version) before assuming publish failed.Report:
main.latest, beta, or next).Take gentleman-programming/release from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.