0

I am trying to install restify but I am getting this error.

c:\Program Files\nodejs>npm install --save restify

 module.js:471

 throw err;



Error: Cannot find module 'c:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js'

at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:389:7)
at startup (bootstrap_node.js:149:9)
at bootstrap_node.js:504:3

can someone help?

StudioTime
  • 22,603
  • 38
  • 120
  • 207

1 Answers1

0

It's not a restify problem. Check your environment variables if they're pointing to your valid local NodeJS bin-directory. Thats the place where your "npm-cli.js" should be.

How to set environment variables on different operating systems: OSX: Setting environment variables in OS X? Windows: https://www.computerhope.com/issues/ch000549.htm Linux: https://www.cyberciti.biz/faq/set-environment-variable-linux/

Tim Haag
  • 11
  • 1
  • 2