简体   繁体   English

无法在Windows中使用Cordova Android?

[英]Cant use cordova android in windows?

After hours of struggling I decided to reread the whole cordova documentation, I noticed this. 经过数小时的奋斗,我决定重新阅读整个cordova文档,我注意到了这一点。

To add support or rebuild a project for any platform, you need to run the command-line interface from the same machine that supports the platform's SDK. 要为任何平台添加支持或重建项目,您需要从支持平台SDK的同一台计算机上运行命令行界面。 The CLI supports the following combinations: CLI支持以下组合:

iOS (Mac)
Android (Mac, Linux) <------
BlackBerry 10 (Mac, Linux, Windows)
Windows Phone 7 (Windows)
Windows Phone 8 (Windows)
Windows 8 (Windows)
Firefox OS (Mac, Linux, Windows)

Is it true that I cant use the cli on windows for android? 我不能在Android的Windows上使用CLI吗? I have the SDK for android installed on my machine, so IDK why it doesn't say windows? 我的机器上安装了适用于Android的SDK,因此IDK为什么不显示Windows?

Are there any workarounds, should I avoid the cli and build my app myself? 有任何解决方法,我应该避免使用cli并自行构建应用程序吗?

The reason why I ask is in the cli I run cordova platform add android I get errors, and have done everything in my power for the last 10 hours to get it to work. 我问的原因是在运行cordova platform add android的cli中cordova platform add android出现错误,并且在过去的10个小时中竭尽所能使其正常工作。

1) You can use CLI commands in windows OS. 1)您可以在Windows OS中使用CLI命令。 I personally develop for Android in windows. 我亲自在Windows中为Android开发。

2) Its highly recommended to use CLI as it makes the life easy for adding/removing any plugin usage. 2)强烈建议使用CLI,因为它使添加/删除任何插件使用变得容易。

3) For the CLI to work correctly, you may require to install Ant, NodeJS. 3)为使CLI正常工作,您可能需要安装Ant,NodeJS。

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

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