1.0.1 • Published 4 years ago

@nielse63/check-node-version v1.0.1

Weekly downloads
1
License
Apache-2.0
Repository
github
Last release
4 years ago

@nielse63/check-node-version

Validates the current node version against the value declared in .nvmrc

Installation

npm i -S @nielse63/check-node-version
yarn add @nielse63/check-node-version

Usage

Node API

const checkNodeVersion = require('@nielse63/check-node-version');

const output = checkNodeVersion();
// { current: '12.10.0', desired: '12.10.0', isEqual: true }

CLI

# install cli
npm i -g @nielse63/check-node-version

check-node-version
# exit code 1 if versions don't match