isaacs / nave

Virtual Environments for Node
ISC License
1.61k stars 137 forks source link

This repository is huge. What is the universal recommended way to install only the files needed to run nave? #120

Closed rulatir closed 1 year ago

rulatir commented 2 years ago

As said in the title, this repository weighs hundreds of megabytes to clone. What is the recommended way to install only the files required to run nave, without transferring the entire repository over the wire? I'm looking for a method that:

Edit: npm install -g nave does not cut it, because I wanto to eventually use nave to isolate npm. If installing nave requires npm, then I'd be dealing with two npms: the bootstrap npm for installing nave, and the regular use npm managed by nave. Ugly.

The basher method doesn't cut it either, because there is at least one "big" distro (Arch) that doesn't have basher in its official repositories or AUR, so installing basher is a nontrivial hurdle at least for the users of this distribution.

isaacs commented 2 years ago

How about this?

curl https://raw.githubusercontent.com/isaacs/nave/main/nave.sh > /path/to/bin/nave
chmod 0755 /path/to/bin/nave

edit autocorrecting "chmod" to "chaos" is so appropriate 😂

rulatir commented 2 years ago

Figured it out in the meantime. I wasn't aware initially that the script is entirely self-contained. Thought that a nontrivial subset of files was needed. Perhaps mention this clearly in the readme? "You can run the script from here" doesn't fully convey the idea that downloading the single script file is all that's required: I understood "from here" to still mean "from complete tree".

"chaos" lol ;)