npm command issue

风格不统一 提交于 2019-12-20 06:18:36

问题


  • I have installed node js on my system. (Windows 7).
  • I have set the environment path variable to "C:\Users\pUser\AppData\Roaming\npm\node_modules\npm".
  • There one .npmrc file in users folder. Which has values set for https_proxy,proxy,registry.
  • I try to check the node version and npm version as follows:

  • a. D:\Pooja Project\project-sd-develop-12>node -v output -->v6.9.4

  • b. D:\Pooja Project\project-sd-develop-12>npm -v (Does not show any result)

    It doesn't respond at all for npm command.Neither any output nor any error. ( It is not even showing any success or error message.) The screen shot attached npm command gets stuck no futher result or any error Am I missing any step?


回答1:


You have set the wrong environment path. It should be:

C:\Users\pUser\AppData\Roaming\npm

not the npm inside node_modules

If Still you are facing the same issue then. By running where npm yOu will get all the paths for npm folder. Then uninstall the node js from your system and delete the npm folder wherever possible. Freshly installed node js.



来源:https://stackoverflow.com/questions/41670317/npm-command-issue

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!