Socket
Socket
Sign inDemoInstall

ensure-node-env

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ensure-node-env

A script that helps ensure you have the correct node & npm versions installed in your environment.


Version published
Weekly downloads
3K
decreased by-54.06%
Maintainers
1
Weekly downloads
 
Created
Source

ensure-node-env

Build Status

A script that helps ensure you have the correct node & npm versions installed in your environment.

Usage

Add the following to your package.json:

  ...
  "engines": {
    "node": "^8.9.0",
    "npm": "^5.5.1"
  },
  "scripts": {
    "preinstall": "node -e \"$(curl -fsSL https://raw.githubusercontent.com/Skyscanner/ensure-node-env/master/dist/index.js)\"",
    ...

Where the node and npm engine properties specify a valid semver range for Node and npm version respectively.

Alternative install via npm

First, install the package globally:

npm install --g ensure-node-env

Then add the following to your package.json:

  ...
  "engines": {
    "node": "^8.9.0",
    "npm": "^5.5.1"
  },
  "scripts": {
    "preinstall": "ensure-node-env",
    ...

Guide

Skyscanner Node development requires Node LTS and npm ^5.5.1. Nvm users can run nvm use to switch to lts/carbon. Nave users can use nave auto. You can also download Node LTS using the website. To install npm ^5.5.1, run npm install --global npm@^5.5.1.

FAQs

Package last updated on 14 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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