Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

check-node-version

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

check-node-version - npm Package Compare versions

Comparing version 2.0.1 to 2.1.0

7

bin.js

@@ -10,3 +10,3 @@ #!/usr/bin/env node

function logVersionError(err) {
function logVersionError(name, err) {
if (err.stderr) {

@@ -30,4 +30,7 @@ console.error(err.stderr);

}
if (info.notfound) {
console.error(name + ': not installed');
}
if (info.error) {
logVersionError(info.error);
logVersionError(name, info.error);
}

@@ -34,0 +37,0 @@ });

@@ -8,2 +8,3 @@ "use strict";

var filterObject = require("object-filter");
var assign = require("object.assign");

@@ -35,3 +36,8 @@ var PROGRAMS = {

var commandDescription = JSON.stringify(command);
if (execError || stderr) {
if (execError && execError.code === 127) {
return callback(null, {
notfound: true,
});
}
else if (execError || stderr) {
var runError = new Error("Command failed: " + commandDescription);

@@ -72,3 +78,3 @@ if (stderr) {

function normalizeOptions(options) {
return Object.assign({
return assign({
getVersion: defaultGetVersion,

@@ -112,2 +118,5 @@ }, options);

}
if (versions[name].notfound) {
programInfo.notfound = versions[name].notfound;
}
if (wanted[name]) {

@@ -114,0 +123,0 @@ programInfo.wanted = new semver.Range(wanted[name]);

{
"name": "check-node-version",
"version": "2.0.1",
"version": "2.1.0",
"description": "Check installed versions of node and npm",

@@ -30,2 +30,3 @@ "main": "index.js",

"object-filter": "^1.0.2",
"object.assign": "^4.0.4",
"run-parallel": "^1.1.4",

@@ -32,0 +33,0 @@ "semver": "^5.0.3"

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc