Commit e9e6c0ca8ffd628fc7c8bfd016099892306bf2e8

Authored by 吴启风
1 parent 18bf346a

fix: 修复分包 APK 输出文件名冲突

Showing 1 changed file with 3 additions and 0 deletions
android/app/build.gradle
@@ -76,8 +76,11 @@ android { @@ -76,8 +76,11 @@ android {
76 variant -> 76 variant ->
77 variant.outputs.all { 77 variant.outputs.all {
78 output -> 78 output ->
  79 + def abi = output.getFilter(com.android.build.OutputFile.ABI)
  80 + def abiSuffix = abi == null ? "" : "_${abi}"
79 output.outputFileName = "wow_${buildType.name}" + 81 output.outputFileName = "wow_${buildType.name}" +
80 "_${defaultConfig.versionName}(${defaultConfig.versionCode})" + 82 "_${defaultConfig.versionName}(${defaultConfig.versionCode})" +
  83 + abiSuffix +
81 "_" + new Date().format("yyyy-MM-dd_HH-mm", TimeZone.getDefault()) + 84 "_" + new Date().format("yyyy-MM-dd_HH-mm", TimeZone.getDefault()) +
82 ".apk" 85 ".apk"
83 } 86 }