@fredlackey/cli-nodetools
v0.0.1
Published
Node.js project tooling CLI for version bump workflows
Maintainers
Readme
cli-nodetools
cli-nodetools is a Node.js CLI scaffold for project tooling workflows.
Package:
@fredlackey/cli-nodetoolsBin:
nodetools
Goal
The initial scope is a single bump command for version bump workflows against packages that already exist in the configured npm registry.
Install
For local development from source:
npm install
node src/bin/nodetools.js --helpAfter global installation:
nodetools --helpCommand Surface
Top-level commands:
nodetools bump [path] --major|--minor|--build [value] [--update [dir]] [--skip-install] [--publish]bump options:
[path]optional folder containingpackage.json; defaults to the current folder.--major [value]bumps the major version. Without a value, uses the next published major version and resets minor/build to0.--minor [value]bumps the minor version for the package's current major version. Without a value, uses the next published minor version and resets build to0.--build [value]bumps the build/patch version for the package's current major and minor version. Without a value, uses the next published build version.--update [dir]updates package references to the bumped package underdir; defaults to the current folder when no dir is provided.--skip-installskips the defaultnpm installin packages changed by--update.--publishrunsnpm installandnpm publishafter updatingpackage.json.
Example:
nodetools bump --minor
nodetools bump --build 42
nodetools bump ../my-package --build
nodetools bump ../my-package --build --update ../workspace
nodetools bump ../my-package --build --update ../workspace --skip-install
nodetools bump ../my-package --minor --publishImplementation notes:
bumprequires exactly one of--major,--minor, or--build.- The target folder must contain a readable and writable
package.json. - The package must already be published in the configured npm registry.
- The command checks published versions before writing a new version.
--updatescans recursively forpackage.jsonfiles, skipsnode_modules, updates dependencies/devDependencies/peerDependencies/optionalDependencies that reference the bumped package, and runsnpm installin each changed package unless--skip-installis supplied.
