use-node

command module
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 5, 2026 License: MIT Imports: 20 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

Overview

usage

No need to setup anything, just run the use-node, then you can use the right node version under your shell.

  • Works the same across Windows, macOS, and Linux.
  • No options, no configs, just run use-node under your node project.
  • Auto-detect the standard engines config recursively from all parent folders.
  • Auto-choose the fastest registry to download node.
  • Auto-cache the node binary.
  • Lightweight and fast.
  • Reports every side-effect it makes on the system, such as where the node is installed.

Installation

Go to the release page and download the use-node binary, run the command below to install use-node to your PATH:

use-node -i

On macOS you might need to do below to trust the binary before run it:

xattr -r -d com.apple.quarantine /path/to/use-node

If you have golang installed:

go install github.com/ysmood/use-node@latest

Use it outside node project

If you want to use it without the package.json file, just specify the node version you want:

use-node v19

If you don't specify a version, it will use the latest node version by default.

Shell Setup

If you want to let it setup PATH env on shell startup, on unix like OS add this line to your .bashrc or .zshrc files:

export PATH=$PATH:$(use-node -p v19.8.1)

If you want to run use-node whenever you cd to a directory, add this line to your .bashrc or .zshrc files:

eval "$(use-node -s)"

On Windows, run use-node -p v19.8.1, copy the output directory path and add it to PATH.

How it works

When you run the use-node. It first recognize the engines field in package.json and automatically download or use the best node version from cache. Then it spawns a sub-shell and inject the node path to your PATH, your current stdio will transparently pipe to the sub-shell.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg
bun

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址