A tool to prevent unnecessary npm publishes in CI/CD by checking if code changes actually warrant a new version. v0.0.8, frequently updated. Unlike standard npm publish, it validates whether a publish is needed, avoiding noisy failures. Ships TypeScript types. Primarily for Node.js/CI environments.
npm install lint-and-publishNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to import and use lint-and-publish to check if publish is needed before actually publishing.
Use await lintAndPublish(...)
Call init() from code
Update import: import fn from 'lint-and-publish' instead of import { publish } from 'lint-and-publish'Run npm install lint-and-publish
Add await: await lintAndPublish(...)
Run npx lint-and-publish --init or call init()