致命错误:生成 cmd ENOENT -- grunt serve [英] Fatal Error: spawn cmd ENOENT -- grunt serve

查看:26
本文介绍了致命错误:生成 cmd ENOENT -- grunt serve的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 grunt serve 命令启动我的 Angular 应用程序但我收到了致命错误:spawn cmd ENOENT.

I am trying to start my angular app using grunt serve command but I am getting Fatal error: spawn cmd ENOENT.

我使用以下命令来生成我的 Angular 应用

I used following commands to generate my Angular App

npm install -g yo grunt-cli bower
npm install -g generator-angular
yo angular
npm install
bower install

然后我使用 grunt serve 命令来启动我的应用

then i used grunt serve command to start my app

但它不起作用.

系统信息:操作系统:Windows 7 64 位npm 版本:2.11.3

System Info: OS: Windows 7 64 bit npm version : 2.11.3

请帮助我,我浏览了所有繁琐的文档,但没有任何线索.

please help me, I gone through all the grunt documentation but no clue.

推荐答案

尝试以下可能的解决方案:

Try the following possible solutions:

  • 验证 npm 文件夹是否存在于以下位置 C:\Users\My-UserName\AppData\Roaming\npm
  • 尝试运行 npm cache clean
  • C:\Windows\System32\ 添加到 PATH 环境变量
  • Verify the npm folder exists at the following location C:\Users\My-UserName\AppData\Roaming\npm
  • Try to run npm cache clean
  • Add C:\Windows\System32\ to the PATH Environment variable

这篇关于致命错误:生成 cmd ENOENT -- grunt serve的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆