0

I use the same project for two machines. I can use Grunt on my iMac with npm 1.4.28 and can't run Grunt with my other machine npm -v 2.5.1

How can I revert my version of npm back to previous version? What if that particular version is not available?

Josh Smith
  • 345
  • 2
  • 5
  • 24
  • I'm gonna take a guess and say that it's not npm that is the issue, but rather node. What does `node --version` spit out on the two boxes? – steveax Feb 12 '15 at 07:14
  • I had a similar issue that was node related, I use nvm to change the version quickly and easily (which also changes node version) I detailed more info here: http://stackoverflow.com/a/28572926/1258242 – joel.software Feb 17 '15 at 23:12

2 Answers2

1

So @steveax was correct, it was a compatibility issue. A few other people experienced the same thing. The repository author issued a great solution, though I would like to see the module and npm latest versions be compatible. But this works now:

On Linux or Mac:

NPM install -g n
n 0.10.33

On Windows:

npm install -g nvmw
nvmw install v0.10.33
nvmw use v0.10.33
Josh Smith
  • 345
  • 2
  • 5
  • 24
-1

what steveax in his comment answered is probably right!

but to answer your question, the crazy stuff about npm is that you can use npm itself to change the version:

$ npm install -g npm@1.4.28
hereandnow78
  • 14,094
  • 8
  • 42
  • 48