- Tests pass (
bun test) - Build works (
bun run build) - CLI works (
node dist/cli.js --version) - README is comprehensive
- LICENSE file exists
- package.json has all required fields
- Update package name to unique npm name
- Update author and repository URLs
- Test locally with
npm link
-
Update package name (if
complexity-analyzeris taken):# Edit package.json to use a unique name like: # "@hew/complexity-analyzer" or "complexity-analyzer-cli"
-
Test locally:
# Build the package bun run build # Test local installation npm link cd /tmp/test-project npm link complexity-analyzer npx complexity-analyzer --version
-
Login to npm:
npm login
-
Publish (dry run first):
# See what would be published npm pack --dry-run # Check package size npm publish --dry-run
-
Actual publish:
npm publish # Or if scoped: npm publish --access public -
Verify installation:
npm install -g complexity-analyzer complexity-analyzer --version
- Create a GitHub release
- Tag the version:
git tag v0.0.1 && git push --tags - Update README with actual npm package name
- Share on social media / dev communities
For future releases:
# Patch release (0.0.1 -> 0.0.2)
npm version patch
# Minor release (0.0.1 -> 0.1.0)
npm version minor
# Major release (0.0.1 -> 1.0.0)
npm version major- Name taken: Add a scope
@username/package-nameor choose unique name - Auth issues: Run
npm loginagain - Size too large: Check
.npmignoreis working - Missing files: Check
filesfield in package.json