Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Cannot find module './nvm-help' #517

Closed
fresheneesz opened this issue Sep 4, 2014 · 12 comments
Closed

Error: Cannot find module './nvm-help' #517

fresheneesz opened this issue Sep 4, 2014 · 12 comments

Comments

@fresheneesz
Copy link
Contributor

I just installed nvm on Centos 6.5 with the command: sudo npm install -g nvm, but when I run nvm -h it gives me the error:

Error: Cannot find module './nvm-help'

@fresheneesz
Copy link
Contributor Author

It kind of looks like everything's broken actually. Trying to do nvm install 0.10.29 gives me:

/home/vagrant/.nvm/node-v0.10.29 doesn't exist, (need to downloaded first?) 0.10.29

even tho the docs say that nvm install should be downloading the files for me. Whats going on? Bad npm release?

@ljharb
Copy link
Member

ljharb commented Sep 4, 2014

That's the wrong nvm package. Don't use that one - install via the readme on this repo.

@ljharb
Copy link
Member

ljharb commented Sep 4, 2014

See https://github.com/brianloveswords/nvm/issues/5 and please indicate your displeasure there.

@ljharb ljharb closed this as completed Sep 4, 2014
@fresheneesz
Copy link
Contributor Author

@ljharb Oh there's actually no way to install nvm via npm? I have to say I'm surprised. Is there a reason for that?

@ljharb
Copy link
Member

ljharb commented Sep 4, 2014

nvm is to install and manage node. You use it to install node in the first place (when you probably don't have it installed at all). Installing a node management tool via node doesn't really make much sense.

That said, if the package name became available on npm, I'd certainly figure out a way to publish it, if only to avoid future confusion.

@fresheneesz
Copy link
Contributor Author

@ljharb Well, so actually, I have primarily used nvm as a way to .. manage versions of node (that's in the name after all). So in all cases i've wanted to use it, I already have node installed, but I want to use a different version of it. Node already has installers, this isn't it. I know i'm not the only one who assumed nvm would be on npm (and got bit by mr pretender over there).

I'd say having a way to use it as a from-scratch installer is great! But it'd also be great to install it via npm if you already have that on your system.

@fresheneesz
Copy link
Contributor Author

Oh also, if you had it on npm, you could simplify your install instructions to:

# if npm doesn't already exist
type npm >/dev/null 2>&1 || { curl http://npmjs.org/install.sh | sh }
npm install the-real-nvm

@shane-reaume
Copy link

@ljharb I don't believe it is always used as a fresh install. For example I have node already and can npm install -g n and it works amazingly.

@ljharb
Copy link
Member

ljharb commented Apr 28, 2015

@ShaneOfAllTrades yes, n and nave require you to have node installed already. The nvm on npm isn't the right one yet, so npm install nvm isn't going to be the right thing.

@ljharb
Copy link
Member

ljharb commented Oct 11, 2015

Duplicate of #304

@gotofritz
Copy link

I am having the exact same problem. Using OS X, and followed the instructions in the README here, i.e.

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.31.0/install.sh | bash

@ljharb
Copy link
Member

ljharb commented Feb 19, 2016

@gotofritz sudo npm uninstall -g nvm?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants