Giter VIP home page Giter VIP logo

nvm.fish's Introduction

nvm.fish

Node.js version manager lovingly made for Fish.

Not that POSIX-compatible script. Designed from the ground up for Fish, this tool helps you manage multiple active versions of Node on a single local environment. Quickly install and switch between runtimes without cluttering your home directory or breaking system-wide scripts.

  • 100% pure Fish—quick & easy to contribute to or change
  • Tab-completable seamless shell integration
  • .node-version and .nvmrc support
  • XDG Base Directory compliant
  • No setup—it just works!

Installation

Install with Fisher:

fisher install jorgebucaran/nvm.fish

Quickstart

Install the latest Node release and activate it.

nvm install latest

Install the latest LTS (long-term support) Node release.

nvm install lts

Install an older LTS release by codename.

Installs 8.16.2, the latest release of the Carbon LTS line.

nvm install carbon

Or install a specific version of Node.

Supports full or partial version numbers, starting with an optional "v".

nvm install v15.3.0

Activate a version you've already installed.

nvm use v14

List which versions you have installed (includes your system-installed Node if there is one).

$ nvm list
     system
    v8.17.0 lts/carbon
    v15.3.0 
 ▶ v14.15.1 lts/fermium
    v18.4.0 latest

Or list all the Node versions that can be installed.

nvm list-remote

Want to uninstall a version?

nvm uninstall v15.3.0

.nvmrc

An .nvmrc file makes it easy to lock a specific version of Node for different projects. Just create an .nvmrc (or .node-version) file containing a version number or alias, e.g., latest, lts, carbon, in the root of your project.

node --version >.nvmrc

Then run nvm install to install or nvm use to activate that version. Works from anywhere inside your project by traversing the directory hierarchy until an .nvmrc is found.

nvm install

$nvm_mirror

Use a mirror of the Node binaries. Default: https://nodejs.org/dist.

$nvm_default_version

The nvm install command activates the specified Node version only in the current environment. If you want to set the default version for new shells use:

set --universal nvm_default_version v18.4.0

$nvm_default_packages

If you have a list of default packages you want installed every time you install a new Node version use:

set --universal nvm_default_packages yarn np

Acknowledgments

nvm.fish started out in 2016 by @jorgebucaran as Fish's premier choice to Node.js version management. All credit to @creationx and @ljharb for creating the one true nvm.sh that served as the inspiration for this project. If you are looking for a way to use the original nvm right from Fish, check out @FabioAntunes/fish-nvm or @derekstavis/plugin-nvm. Thank you to all our contributors! <3

License

MIT

nvm.fish's People

Contributors

briancavalier avatar eugenetriguba avatar fabioantunes avatar franciscolourenco avatar jorgebucaran avatar kallja avatar kidonng avatar klapouchy avatar klesh avatar ktamas avatar myw avatar ngryman avatar raulrpearson avatar ryanq avatar saintwinkle avatar tomyun avatar vincentbel avatar wesbaker avatar yohanboniface avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.