一键导入
npm-release
Prepare, tag, publish, and verify an npm release for this repo. Use when the user wants to release pi-sessions to npm.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Prepare, tag, publish, and verify an npm release for this repo. Use when the user wants to release pi-sessions to npm.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | npm-release |
| description | Prepare, tag, publish, and verify an npm release for this repo. Use when the user wants to release pi-sessions to npm. |
Use this skill when preparing and publishing a new release for pi-sessions.
main..github/workflows/release.yml.CHANGELOG.mdCHANGELOG.md for the annotated git tag body.vX.Y.Z tags.package.json's version is never bumped locally. The tag is the sole source of truth: CI sets the version from the tag in its own ephemeral checkout, and that bump is never committed back to main.Ask the user to confirm the target version unless they already specified it.
Update CHANGELOG.md with a new top entry, Keep a Changelog style:
## [X.Y.Z] - YYYY-MM-DD
- **Short feature title** - One-sentence description of the headline capability.
### Added
- User-facing addition.
### Changed
- User-facing behavior change, including breaking changes (spell out the impact and migration in the bullet itself).
### Fixed
- User-facing bug fix.
### Removed
- User-facing removal.
Only include the headline bullets for releases with a genuine headline capability worth calling out up top; skip them for patch releases, dependency bumps, or single-bullet changes. Only include the other sections that apply; omit empty ones. Keep notes concise. Do not dump every internal refactor. Prefer what a user needs to know.
If the user edits or cleans up the release notes, use their final CHANGELOG.md text for the tag notes later.
If release mechanics change, update this skill and docs/release.md.
Run the full gate and inspect package contents:
npm run check
npm pack --dry-run
Read the tarball contents. Make sure expected source files and dist/session-messaging/broker/process.js are included and obvious junk is absent. The version shown here is package.json's current (stale) version, not the version being released — that's expected; CI sets the real version from the tag.
Do not proceed on failures. Fix them or report the blocker.
Stage only release-relevant files (release notes, code changes — not a package.json version bump) and commit.
If hooks modify staged files, the commit will fail. Ensure the hook is resolved, then recommit.
Push the release prep commit to main.
Use the final CHANGELOG.md entry for the tag notes:
VERSION=X.Y.Z
scripts/extract-release-notes.sh "v${VERSION}" > "/tmp/pi-sessions-v${VERSION}-notes.md"
cat "/tmp/pi-sessions-v${VERSION}-notes.md"
git tag -a "v${VERSION}" --cleanup=verbatim -F "/tmp/pi-sessions-v${VERSION}-notes.md"
git push origin "v${VERSION}"
Do not force-push a stable tag. If a tag already exists, stop and inspect; do not overwrite it. The one exception is a tag whose release workflow never successfully published — that tag is safe to delete and recreate once the underlying issue is fixed and committed.
The tag should trigger the Release workflow.
gh tool to find the release (gh run list --workflow=release.yml).latest dist-tag.Confirm npm and git remote state:
VERSION=X.Y.Z
npm view pi-sessions version dist-tags --json
git ls-remote --tags origin "v${VERSION}"
git status --short
Final report should include: