Release Package
Release the @flareapp/$0 package using release-it. Optional $1 is a version string (patch, minor,
major, or an explicit x.y.z). If $1 is omitted, ask the user which bump is appropriate based on recent
commits before running, then pass it to release-it.
Valid $0 values are the independently versioned packages: core, node, electron, react-native,
react-native-sourcemaps.
If $0 is a lockstep package (js, react, vue, svelte, webpack, vite, sveltekit, nextjs), stop
and tell the user to run npm run release:all instead. Per-package release-it rewrites no cross-package
reference, so releasing a lockstep package this way ships a stale @flareapp/js peer range and breaks the
published entry point.
How publishing works in this repo
release-it is installed once at the repo root, configured per package in packages/$0/.release-it.json.
- Each package has
"release": "release-it" in its package.json scripts.
release-it enforces clean working tree + main branch, bumps version, commits, tags, pushes, then publishes.
prepublishOnly runs the build, so the published artifact is always fresh.
before:release hook runs npm test --if-present. Every package has a test script (vitest run), so the
hook always runs that package's suite.
The release-it flow does not type-check, does not build other packages, and does not run cross-workspace tests.
This skill performs those checks before invoking release-it.
Pre-flight (repo root)
Confirm the working tree is clean and the branch is main:
git status
git rev-parse --abbrev-ref HEAD
If not on main or there are uncommitted changes, abort and tell the user.
Confirm the package exists by reading packages/$0/package.json. Note the current version.
Run cross-workspace validation from the repo root. Abort on any failure:
npm run typescript
npm run test
npm run build
Decide the version
- If
$1 is set, use it as-is.
- If
$1 is empty, summarize the commits since the last @flareapp/$0@* tag (git log @flareapp/$0@<last>..HEAD -- packages/$0)
and propose a bump (patch / minor / major). Ask the user to confirm before continuing.
Cross-package pin check
- If
$0 is core, the exact @flareapp/core pin in packages/js, packages/node, packages/electron,
packages/react, packages/vue, packages/svelte and packages/react-native will still point at the old
version once this release lands, because per-package release-it does not rewrite it. Warn the user, and
point them at npm run release:all, which rewrites those pins and publishes in dependency order. Do not
edit the files automatically.
Confirm
- Show a summary to the user: package, current version, target bump, what
release-it will do
(commit message, tag name, push, npm publish). Ask for explicit confirmation before continuing.
Run release-it
Run from the package directory:
cd packages/$0 && npm run release -- $1
If the user wants a dry run first, add --dry-run:
cd packages/$0 && npm run release -- $1 --dry-run
release-it is interactive. It will prompt for npm OTP if 2FA is on. Pass through any prompts to the user.
If release-it fails:
- Pre-condition failure (dirty tree, wrong branch): fix and retry.
before:release hook failure (test failed): fix the test, do not retry the release until tests pass.
npm publish failure: the git commit and tag may have already been pushed. Investigate before retrying.
Do not blindly re-run npm run release because the version bump commit already exists.
Post-release
Print a summary:
- Package:
@flareapp/$0
- Old version -> new version
- Tag:
@flareapp/$0@<new-version>
- npm:
https://www.npmjs.com/package/@flareapp/$0
Nothing else needs updating. CLAUDE.md records no per-package versions; each package.json is the
source of truth for its own version.
If $0 is core, remind the user to run the sync-versions skill to see which @flareapp/core pins are
now stale.
1---2name: release3description: Release a single independently versioned @flareapp/* package to npm using release-it. Runs cross-workspace pre-flight checks and invokes release-it from the package directory. Not for the lockstep set, which goes through npm run release:all.4---56# Release Package78Release the `@flareapp/$0` package using `release-it`. Optional `$1` is a version string (`patch`, `minor`,9`major`, or an explicit `x.y.z`). If `$1` is omitted, ask the user which bump is appropriate based on recent10commits before running, then pass it to `release-it`.1112Valid `$0` values are the independently versioned packages: `core`, `node`, `electron`, `react-native`,13`react-native-sourcemaps`.1415If `$0` is a lockstep package (`js`, `react`, `vue`, `svelte`, `webpack`, `vite`, `sveltekit`, `nextjs`), stop16and tell the user to run `npm run release:all` instead. Per-package `release-it` rewrites no cross-package17reference, so releasing a lockstep package this way ships a stale `@flareapp/js` peer range and breaks the18published entry point.1920## How publishing works in this repo2122- `release-it` is installed once at the repo root, configured per package in `packages/$0/.release-it.json`.23- Each package has `"release": "release-it"` in its `package.json` scripts.24- `release-it` enforces clean working tree + `main` branch, bumps version, commits, tags, pushes, then publishes.25- `prepublishOnly` runs the build, so the published artifact is always fresh.26- `before:release` hook runs `npm test --if-present`. Every package has a `test` script (`vitest run`), so the27 hook always runs that package's suite.2829The `release-it` flow does not type-check, does not build other packages, and does not run cross-workspace tests.30This skill performs those checks before invoking `release-it`.3132## Pre-flight (repo root)33341. Confirm the working tree is clean and the branch is `main`:3536 ```bash37 git status38 git rev-parse --abbrev-ref HEAD39 ```4041 If not on `main` or there are uncommitted changes, abort and tell the user.42432. Confirm the package exists by reading `packages/$0/package.json`. Note the current `version`.44453. Run cross-workspace validation from the repo root. Abort on any failure:4647 ```bash48 npm run typescript49 npm run test50 npm run build51 ```5253## Decide the version54554. If `$1` is set, use it as-is.565. If `$1` is empty, summarize the commits since the last `@flareapp/$0@*` tag (`git log @flareapp/$0@<last>..HEAD -- packages/$0`)57 and propose a bump (`patch` / `minor` / `major`). Ask the user to confirm before continuing.5859## Cross-package pin check60616. If `$0` is `core`, the exact `@flareapp/core` pin in `packages/js`, `packages/node`, `packages/electron`,62 `packages/react`, `packages/vue`, `packages/svelte` and `packages/react-native` will still point at the old63 version once this release lands, because per-package `release-it` does not rewrite it. Warn the user, and64 point them at `npm run release:all`, which rewrites those pins and publishes in dependency order. Do not65 edit the files automatically.6667## Confirm68697. Show a summary to the user: package, current version, target bump, what `release-it` will do70 (commit message, tag name, push, npm publish). Ask for explicit confirmation before continuing.7172## Run release-it73748. Run from the package directory:7576 ```bash77 cd packages/$0 && npm run release -- $178 ```7980 If the user wants a dry run first, add `--dry-run`:8182 ```bash83 cd packages/$0 && npm run release -- $1 --dry-run84 ```8586 `release-it` is interactive. It will prompt for npm OTP if 2FA is on. Pass through any prompts to the user.8788 If `release-it` fails:89 - Pre-condition failure (dirty tree, wrong branch): fix and retry.90 - `before:release` hook failure (test failed): fix the test, do not retry the release until tests pass.91 - `npm publish` failure: the git commit and tag may have already been pushed. Investigate before retrying.92 Do not blindly re-run `npm run release` because the version bump commit already exists.9394## Post-release95969. Print a summary:97 - Package: `@flareapp/$0`98 - Old version -> new version99 - Tag: `@flareapp/$0@<new-version>`100 - npm: `https://www.npmjs.com/package/@flareapp/$0`101102 Nothing else needs updating. `CLAUDE.md` records no per-package versions; each `package.json` is the103 source of truth for its own version.10410510. If `$0` is `core`, remind the user to run the `sync-versions` skill to see which `@flareapp/core` pins are106 now stale.