Release Checker (alpha)
There are numerous ways to "shoot yourself in the foot" using npm publish
. The purpose of this module is to validate that your project is ready to be published in a safe way.
It checks the following:
- package.json file is valid
- build pass (unreleased)
- tests pass
- there is no sensitive data embedded in the package that will be send to the registry (unreleased)
- there is no useless files (like tests files) embedded in the package that will be send to the registry (unreleased)
- there is no vulnerable dependencies (unreleased)
- there are no uncommitted changes in the working tree (unreleased)
- there are no untracked files in the working tree (unreleased)
- current branch is master (unreleased)
- git tag matches version specified in the
package.json
(unreleased)
Install
-
local install
npm install --save-dev release-checker
Then add this script in the scripts
section of the package.json
file:
"scripts": {
"release-checker": "release-checker"
},
-
global install
npm install -g release-checker
Basic usage
-
local install
npm run release-checker
-
global install
release-checker
-
zero install
npx release-checker
Command-line Options
When you specify no option, all checkers will run.
if you want to run only specific checkers, use the command-line options specific to these checkers.
-h, --help
Displays commands' usage information.
npx release-checker --help
-t, --test (unreleased)
Ensure that command npm test
is successfull
npx release-checker --test
Authors
This project is a port of all validations provided by publish-please