简体   繁体   English

离子中的“错误;生成 cmd ENOENT”(离子构建 android 命令)

[英]"Error ; spawn cmd ENOENT" in ionic (ionic build android command)

I am building an app using ionic framework.我正在使用离子框架构建一个应用程序。 when I execute the command 'ionic build android' it is showing the following message.当我执行命令“ionic build android”时,它显示以下消息。

C:\Windows\System32\todo>ionic build android
Running command: "C:\Program Files\nodejs\node.exe" C:\Windows\System32\todo\hooks\after_prepare\010_add_platform_class.js C:\Windows\System32\todo
add to body class: platform-android
ANDROID_HOME=C:\Program Files (x86)\Android\android-sdk\
JAVA_HOME=C:\Program Files\java\jdk1.8.0_66

Error: spawn cmd ENOENT

I am running it on a windows 7 system using node.js command prompt我使用 node.js 命令提示符在 Windows 7 系统上运行它

I have googled, but couldn't find any helpful solution.我用谷歌搜索,但找不到任何有用的解决方案。 Plese help.请帮忙。 Thanks in advance提前致谢

此问题可能是由于您未在环境变量中设置 npm(C:\\Users\\\\AppData\\Roaming\\npm) 的当前路径。

On some systems, it was the problem of access:在某些系统上,这是访问问题:

Android Studio 3.0 removes the execute permission from Gradle, breaking the build

you can change the permissions and check the result!您可以更改权限并检查结果!

The problem may come from windows services.问题可能来自 Windows 服务。 Windows child process services not running properly. Windows 子进程服务未正常运行。 In windows, OS => Go to System Config and enable all services and restart the computer.在 Windows 中,OS => 转到系统配置并启用所有服务并重新启动计算机。 For more details check here .有关更多详细信息, 请查看此处

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM