蚂蚁不添加时发现的问题 android 在 window7 平台

标签: Ant Android windows
发布时间: 2014/8/24 4:42:31
注意事项: 本文中文内容可能为机器翻译,如要查看英文原文请点击上面连接.

enter image description here当我想要运行下面的命令我是竞争蚂蚁不安装错误。

C:\MyApp\Android\MySpe\Audio>cordova platform add android
Creating android project...

C:\Users\atulc\.cordova\lib\android\cordova\3.4.0\bin\node_modules\q\q.js:126
                    throw e;
                          ^
Error: ERROR : executing command 'ant', make sure you have ant installed and add
ed to your path.
    at C:\Users\atulc\.cordova\lib\android\cordova\3.4.0\bin\lib\check_reqs.js:4
7:27
    at ChildProcess.exithandler (child_process.js:641:7)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:743:16)
    at Socket.<anonymous> (child_process.js:956:11)
    at Socket.EventEmitter.emit (events.js:95:17)
    at Pipe.close (net.js:465:12)
Error: C:\Users\atulc\.cordova\lib\android\cordova\3.4.0\bin\create.bat: Command
 failed with exit code 8
    at ChildProcess.whenDone (C:\Users\atulc\AppData\Roaming\npm\node_modules\co
rdova\src\superspawn.js:126:23)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:743:16)
    at Process.ChildProcess._handle.onexit (child_process.js:810:5)

我也有更新我 Environment 变量 accrodingly,但仍然得到上述提到的错误:-

更高: C:\ant JAVA_HOME:C:\Program Files\Java\jdk1.7.0_21\ 和 path 变量,以及。

真的很感谢任何帮助。

解决方法 1:

您需要更新您 PATH environment 变量。如果您已经创建了更高 environment 变量,将它添加到你 PATH

PATH = "(current_path);%ANT_HOME%\bin"

ANT_HOME

Path

赞助商