'nodemon'不被识别为内部或外部命令,可操作程序或批处理文件
我正在尝试全局安装nodemon,但我收到的警告如附图中所述。可能是因为警告,我无法运行nodemon。我的package.json
{
"name": "learn",
"version": "1.0.0",
"description": "",
"main": "server.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"start": "node server.js"
},
"author": "himanshu",
"license": "ISC",
"dependencies": {
"bcrypt-nodejs": "0.0.3",
"body-parser": "^1.17.2",
"express": "^4.15.4",
"mongoose": "^4.11.7",
"morgan": "^1.8.2"
}
}
回答如下:
我已将C:\Users\username\AppData\Roaming\npm
添加到我的系统的环境变量中,它解决了我的问题。