如果从Jenkins运行,Crashlytics gradle插件找不到APK

时间:2016-02-17 12:47:31

标签: android jenkins android-gradle crashlytics crashlytics-android

我即将配置Jenkins以将构建升级到Fabric,但它没有找到正确的位置,因此在运行此命令时出现以下错误:

gradle assembleStaging crashlyticsUploadDistributionApplication-Staging

Uploading /Users/jenkins/.jenkins/jobs/testPromoteBuildsOnCrashlytics/workspace/Application/build/outputs/apk/Application-staging.apk to Crashlytics...
 WARN - Crashlytics halted compilation because it can't find the specified file: /Users/jenkins/.jenkins/jobs/testPromoteBuildsOnCrashlytics/workspace/Application/build/outputs/apk/Application-staging.apk

有没有办法告诉crashlytics插件实际构建的位置?

1 个答案:

答案 0 :(得分:2)

在build.gradle中,您可以添加:

ext.betaDistributionApkFilePath = '/path/to/your/apk'

crashlytics {}块或您的相应构建变体的{}块。