相关疑难解决方法(0)

nodemon无法正常工作:-bash:nodemon:command not found

我在Mac上运行El Capitan.我有节点v5.6.0和npm v3.6.0.当我尝试运行nodemon时,我得到:

-bash: nodemon: command not found
Run Code Online (Sandbox Code Playgroud)

我认为这可能意味着我没有安装nodemon,所以当我尝试使用...时安装它

sudo npm install -g nodemon
Run Code Online (Sandbox Code Playgroud)

......我明白了:

npm ERR! Darwin 15.2.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g"     "nodemon"
npm ERR! node v5.6.0
npm ERR! npm  v3.6.0
npm ERR! path /usr/local/bin/nodemon
npm ERR! code EEXIST

npm ERR! Refusing to delete /usr/local/bin/nodemon: ../lib/node_modules/nodemon/nodemon.js symlink target is not controlled by         npm /usr/local
npm ERR! File exists: /usr/local/bin/nodemon
npm ERR! Move it away, and try again.

npm ERR! Please include the following file with any …
Run Code Online (Sandbox Code Playgroud)

bash node.js npm express nodemon

29
推荐指数
15
解决办法
4万
查看次数

标签 统计

bash ×1

express ×1

node.js ×1

nodemon ×1

npm ×1