-
Notifications
You must be signed in to change notification settings - Fork 66
Description
A single gradle command could generate multiple APKs. One of the most common usecases are,
- debug & release flavor
- multiple builds pointing to development, staging, pre-prod and prod backend end points.
Fastlane correctly recognizes them and the following Lane Context variables reflect the same.
GRADLE_ALL_APK_OUTPUT_PATHS = [
"/some-path/app/build/outputs/apk/prod/debug/App-prod-debug-1.0.0(3).apk",
"/some-path/app/build/outputs/apk/stage/debug/App-stage-debug-1.0.0(3).apk",
"/some-path/app/build/outputs/apk/dev/debug/COTO-dev-debug-1.0.0(3).apk"]
GRADLE_ALL_OUTPUT_JSON_OUTPUT_PATHS = [
"/some-path/app/build/outputs/apk/prod/debug/output-metadata.json",
"/some-path/app/build/outputs/apk/stage/debug/output-metadata.json",
"/some-path/app/build/outputs/apk/dev/debug/output-metadata.json"]
===
fastlane-plugin-s3, at the moment accepts only a single APK path via apk
param. Also it (correctly) defaults it to lane context variable GRADLE_APK_OUTPUT_PATH
This approach requires app devs to publish each APK seperately.
Instead, if we could allows all APKs to be published in one go, and offer a way to list the links for each APK in the HTML as well, it would be a great feature.
The plugin could accept apkPaths
param which takes an array of paths. It could be defaulted to GRADLE_ALL_APK_OUTPUT_PATHS
for out of the box setup. The value of apkPaths
will end up overriding apk
and hopefully it would cause any issues. Because even in circumstances where the gradle task generates a single APK, GRADLE_ALL_APK_OUTPUT_PATHS
would still include that one APK path.
Note:
Though multiple IPAs could possibly be built using custom xcode targets, I am not sure whether Fastlane identifies them and sets the approapriate Lane Context variables.