简体   繁体   English

是否有命令行工具来下载Android模拟器图像(AVD Manager)?

[英]Is there a command line tool to download Android emulator images (AVD Manager)?

I'm trying to build a docker image with the Android emulator for testing purposes with Appium, and I've got all necessary except the avd images. 我正在尝试使用Android模拟器构建一个docker镜像,以便用Appium进行测试,除了avd图像之外我还有其他必要的东西。 For now, when I run android list avd I have an empty list. 现在,当我运行android list avd我有一个空列表。

I have installed the following tools, but I missed some documentation about how to use them to retrieve images: android update sdk -t tool,platform-tool,android-24,addon-google_apis-google-24,extra-google-webdriver . 我已经安装了以下工具,但我错过了一些关于如何使用它们来检索图像的文档: android update sdk -t tool,platform-tool,android-24,addon-google_apis-google-24,extra-google-webdriver

Edit: I'm working with android-sdk_r24.4.1-linux.tgz . 编辑:我正在使用android-sdk_r24.4.1-linux.tgz

I've tried android create avd -t android-24 -n android-24-avd which said Error: This platform has more than one ABI. Please specify one using --abi. 我试过android create avd -t android-24 -n android-24-avd ,它说Error: This platform has more than one ABI. Please specify one using --abi. Error: This platform has more than one ABI. Please specify one using --abi. , but android-24 has no ABI android-24没有ABI

Available Android targets:
----------
id: 1 or "android-24"
     Name: Android 7.0
     Type: Platform
     API level: 24
     Revision: 2
     Skins: HVGA, QVGA, WQVGA400, WQVGA432, WSVGA, WVGA800 (default), WVGA854, WXGA720, WXGA800, WXGA800-7in
 Tag/ABIs : no ABIs.
----------
id: 2 or "Google Inc.:Google APIs:24"
     Name: Google APIs
     Type: Add-On
     Vendor: Google Inc.
     Revision: 1
     Description: Android + Google APIs
     Based on Android 7.0 (API level 24)
     Libraries:
      * com.android.future.usb.accessory (usb.jar)
          API for USB Accessories
      * com.google.android.media.effects (effects.jar)
          Collection of video effects
      * com.google.android.maps (maps.jar)
          API for Google Maps
     Skins: HVGA, QVGA, WQVGA400, WQVGA432, WSVGA, WVGA800 (default), WVGA854, WXGA720, WXGA800, WXGA800-7in
 Tag/ABIs : no ABIs.

You can do this with the --components option for android update sdk . 您可以使用--components选项为android update sdk执行此操作。 For example 例如

$ android update sdk --components=sys-img-x86-android-18

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

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