Successor to irish-pub
. Feel like npm is drunk or maybe you are and want to verify what gets published via npm publish
? canadian-pub
has you covered.
➝ canadian-pub
npm will publish canadian-pub@1.0.0 as vweevers, including the following files eh:
package.json
index.js
LICENSE.md
README.md
bin/canadian-pub.js
Similar to npm pack --dry-run
but less noisy and printing files to stdout instead of stderr. In addition canadian-pub
protects you from common mistakes, printing errors to stderr and exiting with code 1
:
3 blacklisted:
.travis.yml
deps/snappy/snappy.sln
.nyc_output/9daf5b463f958a9071a9efcc7fbac6d9
This makes it useful as an npm prepublish(Only)
script. Add --silent
or -s
to skip printing files. E.g.:
"scripts": {
"prepublishOnly": "canadian-pub -s"
}
With npm do:
npm install canadian-pub --save-dev
Or globally:
npm install canadian-pub -g
canadian-pub [root] [--silent/-s] [--verbose]
See description of root
and options below.
Invokes npm pack --ignore-scripts
to determine what would be included during npm publish
. The root
argument should be the path to the package to publish and defaults to the current working directory.
Returns a readable stream that yields file paths relative to root
.
silent
: boolean. Skip printing files.verbose
: boolean (cli only). Print stack traces.
MIT © 2018-present Vincent Weevers. Adapted from irish-pub
, copyright © 2014 Thorsten Lorenz.