科尔多瓦模拟android退出代码1 [英] Cordova emulate android Exit Code 1

查看:60
本文介绍了科尔多瓦模拟android退出代码1的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有通过Cordova成功构建的代码.但是,当我尝试模拟它时,出现此错误"Error:cmd:命令失败,退出代码为1".关于如何解决此问题的任何想法?这是我尝试模拟代码的结果

I have code that is building successfully through cordova. However, when I try to emulate it, I get this error "Error:cmd: Command failed with exit code 1". Any ideas on how to fix this?Here is my output from attempting to emulate the code

推荐答案

我遇到了同样的问题.看来您没有任何AVD正在运行.我不认为ionic的教程指定您需要这样做.我假设您正在遵循指南.

I had the same problem. It looks like you don't have any AVD running. I don't think ionic's tutorial specifies that you need to do that. I assume you're following this guide.

要解决此问题(如果您遇到的错误也是由于缺少Android虚拟设备而导致的),

To fix the issue (if the error in your case is also caused by the lack of Android Virtual Device running) simply:

  1. 启动Android Studio.

  1. Start Android Studio.

导航至工具-> Android-> AVD管理器.

Navigate to Tools -> Android -> AVD Manager.

创建虚拟设备(左下角的按钮).

Create virtual device (button on the bottom left corner).

通过配置设备来设置它以满足您的需求.

Set up the device by configuring it to suit your needs.

通过在AVD Manager中按操作"列下的绿色三角形来运行虚拟设备(应弹出带有模拟电话的新窗口).

Run the virtual device by pushing the green triangle in AVD Manager, under "Actions" column (a new window with the emulated phone should pop up).

再次运行ionic emulate android命令.

请注意,如果出于某种原因,在工具"菜单下没有"Android"子菜单(这是我的第一个问题),则只需再次启动Android Studio安装程序,然后重新安装,请确保您可以在安装过程中选中"Android虚拟设备"框.

Note that if you - for some reason - don't have "Android" submenu under "Tools" menu (that was my first issue), you have to simply start the Android Studio installer once more and reinstall it, making sure you check the box for Android Virtual Device during installation.

这篇关于科尔多瓦模拟android退出代码1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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