【问题标题】:Travis Ci build error caused by Android SDK license agreementsAndroid SDK 许可协议导致 Travis Ci 构建错误
【发布时间】:2017-02-24 18:05:19
【问题描述】:

我有使用 CircleCi 的经验:

https://circleci.com/gh/mmirhoseini/fyber_mobile_offers/28

但我无法使用 TravisCi 上的同一存储库解决此许可证问题:

https://travis-ci.org/mmirhoseini/fyber_mobile_offers/builds/167852390

这是 travis 错误日志:

FAILURE:构建失败并出现异常。

出了什么问题:配置项目 ':fyber-app' 时出现问题。

您尚未接受以下 SDK 组件的许可协议:[SDK Patch Applier v1, Google Repository]。

在构建项目之前,您需要接受许可协议并使用 Android Studio SDK 管理器完成缺失组件的安装。或者,要了解如何将许可协议从一个工作站转移到另一个工作站,请转至 http://d.android.com/r/studio-ui/export-licenses.html

我知道这是一个许可证问题,但不知道如何解决。这是我的 .travis.yml 文件:

language: android

sudo: required

android:
  components:
    - tools
    - platform-tools
    - build-tools-24.0.2
    - android-24
    - extra-android-m2repository
  licenses:
    - 'android-sdk-preview-license-.+'
    - 'android-sdk-license-.+'
    - 'intel-android-extra-license.+'

jdk:
  - oraclejdk8

before_install:
  - chmod +x gradlew

script:
  - ./gradlew build

【问题讨论】:

    标签: android continuous-integration travis-ci


    【解决方案1】:

    您似乎缺少 google 存储库。

    添加- extra-google-m2repository 并再次尝试构建。

    这是我的 .travis.yml 供参考:

    language: android
    android:
      components:
        - tools
        - platform-tools
        - build-tools-24.0.3
        - android-24
        - extra-android-m2repository
        - extra-google-m2repository
        - extra-android-support
        - extra-google-google_play_services
    jdk:
      - oraclejdk8
    script:
      - ./gradlew test
    

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2018-03-27
    • 2017-05-17
    • 2017-03-16
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多