Skip to content

Commit

Permalink
Improve output APK name
Browse files Browse the repository at this point in the history
  • Loading branch information
Mahmud0808 committed Dec 9, 2023
1 parent 5087878 commit 5e55e22
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import com.android.build.gradle.internal.api.BaseVariantOutputImpl

plugins {
id("com.android.application")
}
Expand All @@ -10,8 +12,8 @@ android {
applicationId = "com.drdisagree.colorblendr"
minSdk = 31
targetSdk = 34
versionCode = 1
versionName = "1.0 beta 1"
versionCode = 2
versionName = "1.0 beta 2"

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}
Expand All @@ -23,6 +25,16 @@ android {
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)

applicationVariants.all {
val variant = this
variant.outputs
.map { it as BaseVariantOutputImpl }
.forEach { output ->
val outputFileName = "ColorBlendr ${variant.versionName}.apk"
output.outputFileName = outputFileName
}
}
}
}
compileOptions {
Expand Down

0 comments on commit 5e55e22

Please sign in to comment.