gnode

command module
v0.0.0-...-742a8ad Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2020 License: MIT Imports: 11 Imported by: 0

README

Gnode

Project Level NodeJs version manager.

Installation

$ go get github.com/cjtoolkit/gnode

If you haven't got go installed, you can use the pre compiled binary instead
https://github.com/cjtoolkit/gnode/releases
Rename it to gnode or gnode.exe (if windows) and add it to the path (e.g. /usr/bin).

Using Gnode

Create .gnode in the root of the project, with the example below.

{
  "version": "12.16.2",
  "modules": [
    {
      "package": "yarn",
      "version": "1.22.4"
    }
  ]
}

The first parameter of gnode will point to a file in Node's bin directory, for example.

To use node run $ gnode node
To use npm run $ gnode npm
To use yarn run $ gnode yarn

If node is not install in ~/sdk, it will download Node and install it automatically, along with the modules specified in .gnode.

Note

You add add "no_npm": true to the root of .gnode and that will strip out npm after installation.

It's currently compatible with Windows, Linux and Mac.

Mac has not been tested, yet.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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