npm view @ohmaseclaro/fleetwatch
# E404 means free; otherwise pick another name or use a scope (@user/fleetwatch).npm login
npm whoami # → your usernameA regular login token won't be allowed to npm publish — you'll get
E403 … Two-factor authentication … required. Two ways around it:
Per-publish OTP — pass a fresh 6-digit code from your authenticator app:
npm publish --access public --otp=123456
# or
./scripts/release.sh patch --otp=123456One-time setup — Automation token (recommended for releases):
- https://www.npmjs.com/settings/~/tokens → Generate New Token
- Pick either:
- Classic Token → Automation — bypasses 2FA, scoped to all your packages
- Granular Access Token — check Bypass two-factor authentication,
scope to the
fleetwatchpackage only
- Save the token:
npm config set //registry.npmjs.org/:_authToken=<token>
- From now on
npm publishworks without OTP.
For automated publishing on git tag push:
- Create an automation token at <https://www.npmjs.com/settings//tokens> (type: "Automation", grants publish).
- Add it as a GitHub secret:
gh secret set NPM_TOKEN --body <your-token> - Push a tag (
git push --tags) —.github/workflows/publish.ymlruns.
Use the release script. It:
- Verifies the working tree is clean and you're on main/master
- Confirms you're logged into npm
- Runs typecheck + build
- Bumps the version
- Creates a
vX.Y.Zcommit + tag - Publishes to npm
- Pushes to GitHub
./scripts/release.sh patch # 0.1.0 → 0.1.1
./scripts/release.sh minor # 0.1.0 → 0.2.0
./scripts/release.sh major # 0.1.0 → 1.0.0If you've configured NPM_TOKEN in GitHub, you can skip the script entirely:
just bump + tag locally and push, and the workflow publishes for you.
The files field in package.json whitelists exactly what ships:
dist/server/**— compiled daemon JS + typesdist/web/**— built PWA bundle (HTML, CSS, JS, manifest, icons)README.mdLICENSE.env.example
Anything else (src/, server/, docs/, etc.) stays in the git repo
but is excluded from the tarball.
To preview what npm publish will upload:
npm pack --dry-run-
npm view @ohmaseclaro/fleetwatchshows the new version -
npx @ohmaseclaro/fleetwatch@latestruns cleanly on a machine that's never seen the package - The web UI loads at the URL printed in the banner
- A QR scan from your phone connects successfully