Skip to content

Commit

Permalink
feat: Add feature flavor
Browse files Browse the repository at this point in the history
* #102

Change-Id: I673226291a70c20ab41639f54be46b027b3dda73
  • Loading branch information
XayahSuSuSu committed Mar 4, 2023
1 parent b343423 commit 2d0af02
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ android {
}
}

flavorDimensions "common"
flavorDimensions "common", "feature"
productFlavors {
"arm64-v8a" {
dimension "common"
Expand All @@ -37,6 +37,12 @@ android {
"x86_64" {
dimension "common"
}
"foss" {
dimension "feature"
}
"premium" {
dimension "feature"
}
}

buildTypes {
Expand Down Expand Up @@ -74,7 +80,7 @@ android {
android.applicationVariants.all {
variant ->
variant.outputs.all {
outputFileName = "DataBackup-${variant.versionName}-${variant.productFlavors[0].name}-${variant.buildType.name}.apk".replaceAll("\\*", "")
outputFileName = "DataBackup-${variant.versionName}-${variant.productFlavors[0].name}-${variant.productFlavors[1].name}-${variant.buildType.name}.apk".replaceAll("\\*", "")
}
}
}
Expand Down Expand Up @@ -150,7 +156,7 @@ dependencies {
implementation "com.google.accompanist:accompanist-drawablepainter:$accompanistVersion"

// Firebase
implementation platform('com.google.firebase:firebase-bom:31.2.2')
implementation 'com.google.firebase:firebase-analytics-ktx'
implementation 'com.google.firebase:firebase-crashlytics-ktx'
"premiumImplementation" platform('com.google.firebase:firebase-bom:31.2.2')
"premiumImplementation" 'com.google.firebase:firebase-analytics-ktx'
"premiumImplementation" 'com.google.firebase:firebase-crashlytics-ktx'
}

0 comments on commit 2d0af02

Please sign in to comment.