不同渠道文件名不同

pull/352/head
gedoor 4 years ago
parent d034f99efb
commit 82f8c15f09
  1. 9
      app/build.gradle

@ -19,7 +19,6 @@ def gitCommits = Integer.parseInt('git rev-list --count HEAD'.execute([], projec
android { android {
compileSdkVersion 29 compileSdkVersion 29
flavorDimensions("version")
signingConfigs { signingConfigs {
if (project.hasProperty("RELEASE_STORE_FILE")) { if (project.hasProperty("RELEASE_STORE_FILE")) {
myConfig { myConfig {
@ -71,17 +70,19 @@ android {
} }
android.applicationVariants.all { variant -> android.applicationVariants.all { variant ->
variant.outputs.all { variant.outputs.all {
outputFileName = "${name}_${defaultConfig.versionName}.apk" def flavor = variant.productFlavors[0].name
outputFileName = "${name}_${flavor}_${defaultConfig.versionName}.apk"
} }
} }
} }
flavorDimensions "mode"
productFlavors { productFlavors {
app { app {
dimension "version" dimension "mode"
manifestPlaceholders = [APP_CHANNEL_VALUE: "app"] manifestPlaceholders = [APP_CHANNEL_VALUE: "app"]
} }
google { google {
dimension "version" dimension "mode"
applicationId "io.legado.play" applicationId "io.legado.play"
manifestPlaceholders = [APP_CHANNEL_VALUE: "google"] manifestPlaceholders = [APP_CHANNEL_VALUE: "google"]
} }

Loading…
Cancel
Save