❯ npx npm-publish-files --helpUsage: npm-publish-files [options] <dir>Copy special files `npm publish` always includes to a sub directoryOptions:-V, --version output the version number-f, --force overwrite existing files-c, --clean remove files instead of copying-i, --include <glob> glob
If you want to build a large npm project into a sub folder
dist/, but then treat that as the root directory for the published package, you will need to copy all other special files npm includes in the publish. Let
npm-publish-files do that for you!
This script will make sure all necessary files are copied to
dist/ before running
Any additional files specified in the "file" property of package.json will also be copied.
After this your are free to run
npm publish dist.
npm-publish-files uses the npm-packlist package under the hood to determine which files to copy. Please read its readme to better understand the algorhithm.
To copy additional files, supply one or more globs with the
--include option. All matched files will be copied to
To exclude files from being copied, supply one or more globs with the
--exclude option. These will be applied last, so they filter both the default files, as well as those matched via the