美文网首页
center os 采用yum安装 npm 后找不到npm的命令

center os 采用yum安装 npm 后找不到npm的命令

作者: changlinwang | 来源:发表于2017-07-03 14:45 被阅读58次
 问题:
 Cannot find module :'/usr/local/lib/node_modules/npm/bin/node_modules/npm/bin/npm-cli.js'

My guess is it has something to do with PATHs but I am not well learned in this area. Please ask if you need anymore info. Thanks.

Edit

So the path it is looking for the npm_cli module is pretty wacky 
/usr/local/lib/node_modules/npm/bin/node_modules/npm/bin

 The path that npm_cli.js is located at is:

 /usr/local/lib/node_modules/npm/bin

 So there's the issue but I still don't actually know how to fix it.

Edit 2

 Here are the relevant entries in my .bash_profile

 export PATH="/usr/local/lib/node_modules/npm/bin:/usr/local/heroku/bin:$PATH"
 export NODE_PATH="/usr/local/lib/node"

相关文章

网友评论

      本文标题:center os 采用yum安装 npm 后找不到npm的命令

      本文链接:https://www.haomeiwen.com/subject/qvaacxtx.html