- β Checks if a Node app is running on the right Node version
- β Fails with a message to update Node version to specified version
npm install cli-check-nodeconst checkNode = require('cli-check-node');
checkNode('13'); // Fails the script if current node version is less than 13.Type: string
Type: object
Default: {fail: true} (optional)
You can specify the options below.
Type: boolean
Default: true (optional)
checkNode('13', {fail: false});
// Notifies if current node version is less than 13. Does NOT fail.β― Read the changelog here β
KEY: π¦ NEW, π IMPROVE, π FIX, π DOC, π RELEASE, and β
TEST
I use Emoji-log, you should try it and simplify your git commits.
- MIT Β© Ahmad Awais
- Code of Conduct