Skip to content

Commit

Permalink
Merge pull request #111 from niscy-eudiw/main
Browse files Browse the repository at this point in the history
Minor refactor with more generic Names for Build Configuration Files
  • Loading branch information
stzouvaras authored May 30, 2024
2 parents 8944716 + aab39a4 commit 05d7ac6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* governing permissions and limitations under the Licence.
*/

import eu.europa.ec.euidi.EudiBuildType
import eu.europa.ec.euidi.AppBuildType
import eu.europa.ec.euidi.config.LibraryModule
import eu.europa.ec.euidi.getProperty

Expand Down Expand Up @@ -53,12 +53,12 @@ android {
debug {
isDebuggable = true
isMinifyEnabled = false
applicationIdSuffix = EudiBuildType.DEBUG.applicationIdSuffix
applicationIdSuffix = AppBuildType.DEBUG.applicationIdSuffix
}
release {
isDebuggable = false
isMinifyEnabled = false
applicationIdSuffix = EudiBuildType.RELEASE.applicationIdSuffix
applicationIdSuffix = AppBuildType.RELEASE.applicationIdSuffix
signingConfig = signingConfigs.getByName("release")
proguardFiles(getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ package eu.europa.ec.euidi
/**
* This is shared between :app and modules to provide configurations type safety.
*/
enum class EudiBuildType(val applicationIdSuffix: String? = null) {
enum class AppBuildType(val applicationIdSuffix: String? = null) {
DEBUG,
RELEASE
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ enum class FlavorDimension {
contentType
}

enum class EudiFlavor(
enum class AppFlavor(
val dimension: FlavorDimension,
val applicationIdSuffix: String? = null,
val applicationNameSuffix: String? = null
Expand All @@ -38,12 +38,12 @@ enum class EudiFlavor(
fun configureFlavors(
commonExtension: CommonExtension<*, *, *, *, *, *>,
version: String,
flavorConfigurationBlock: ProductFlavor.(flavor: EudiFlavor) -> Unit = {}
flavorConfigurationBlock: ProductFlavor.(flavor: AppFlavor) -> Unit = {}
) {
commonExtension.apply {
flavorDimensions += FlavorDimension.contentType.name
productFlavors {
EudiFlavor.values().forEach {
AppFlavor.values().forEach {
create(it.name.lowercase()) {
val fullVersion = "$version-${it.name}"
dimension = it.dimension.name
Expand Down

0 comments on commit 05d7ac6

Please sign in to comment.