Updated on 2026-08-14
This commit is contained in:
parent
075bb9af91
commit
2666e76a04
14 changed files with 112 additions and 102 deletions
|
|
@ -72,7 +72,9 @@ private fun AndroidBuildType.configureBuildVariant(extension: AppExtension, buil
|
|||
isDebuggable = true
|
||||
isMinifyEnabled = false
|
||||
}
|
||||
BuildType.External -> {
|
||||
BuildType.Internal,
|
||||
BuildType.External,
|
||||
-> {
|
||||
initWith(extension.buildTypes.getByName(BuildType.Release.id))
|
||||
signingConfig = extension.signingConfigs.getByName(BuildType.Debug.id)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,6 +7,72 @@ internal enum class BuildType(
|
|||
val configFields: List<BuildConfigField>,
|
||||
) {
|
||||
|
||||
/**
|
||||
* Build type for developers
|
||||
*
|
||||
* Features:
|
||||
* - Env: dev
|
||||
* - Signing config: debug
|
||||
* - Debuggable
|
||||
* - Logs
|
||||
* - Tester menu
|
||||
* - Test action
|
||||
* - Traffic sniffing
|
||||
* */
|
||||
Debug(
|
||||
id = "debug",
|
||||
appIdSuffix = "debug",
|
||||
configFields = listOf(
|
||||
BuildConfigField.Environment(value = "dev"),
|
||||
BuildConfigField.TestActionEnabled(isEnabled = true),
|
||||
BuildConfigField.LogEnabled(isEnabled = true),
|
||||
BuildConfigField.TesterMenuAvailability(isEnabled = true),
|
||||
),
|
||||
),
|
||||
|
||||
/**
|
||||
* Build type for QA
|
||||
*
|
||||
* Features:
|
||||
* - Env: beta
|
||||
* - Signing config: debug
|
||||
* - Logs
|
||||
* - Tester menu
|
||||
* - Test action
|
||||
* - Traffic sniffing
|
||||
* */
|
||||
Internal(
|
||||
id = "internal",
|
||||
appIdSuffix = "internal",
|
||||
versionSuffix = "internal",
|
||||
configFields = listOf(
|
||||
BuildConfigField.Environment(value = "beta"),
|
||||
BuildConfigField.TestActionEnabled(isEnabled = true),
|
||||
BuildConfigField.LogEnabled(isEnabled = true),
|
||||
BuildConfigField.TesterMenuAvailability(isEnabled = true),
|
||||
),
|
||||
),
|
||||
|
||||
/**
|
||||
* Build type for QA and business
|
||||
*
|
||||
* Features:
|
||||
* - Env: prod
|
||||
* - Signing config: debug
|
||||
* - Proguard
|
||||
* */
|
||||
External(
|
||||
id = "external",
|
||||
appIdSuffix = "external",
|
||||
versionSuffix = "external",
|
||||
configFields = listOf(
|
||||
BuildConfigField.Environment(value = "prod"),
|
||||
BuildConfigField.TestActionEnabled(isEnabled = false),
|
||||
BuildConfigField.LogEnabled(isEnabled = false),
|
||||
BuildConfigField.TesterMenuAvailability(isEnabled = false),
|
||||
),
|
||||
),
|
||||
|
||||
/**
|
||||
* Production ready build type for clients
|
||||
*
|
||||
|
|
@ -24,49 +90,4 @@ internal enum class BuildType(
|
|||
BuildConfigField.TesterMenuAvailability(isEnabled = false),
|
||||
),
|
||||
),
|
||||
|
||||
/**
|
||||
* Build type for developers
|
||||
*
|
||||
* Features:
|
||||
* - Env: dev
|
||||
* - Signing config: debug
|
||||
* - Debuggable
|
||||
* - Logs
|
||||
* - Tester menu
|
||||
* - Test action
|
||||
* - Traffic sniffing
|
||||
* */
|
||||
Debug(
|
||||
id = "debug",
|
||||
appIdSuffix = "dev",
|
||||
configFields = listOf(
|
||||
BuildConfigField.Environment(value = "dev"),
|
||||
BuildConfigField.TestActionEnabled(isEnabled = true),
|
||||
BuildConfigField.LogEnabled(isEnabled = true),
|
||||
BuildConfigField.TesterMenuAvailability(isEnabled = true),
|
||||
),
|
||||
),
|
||||
|
||||
/**
|
||||
* Build type for QA and business
|
||||
*
|
||||
* Features:
|
||||
* - Env: prod
|
||||
* - Signing config: debug
|
||||
* - Tester menu
|
||||
* - Test action
|
||||
* - Proguard
|
||||
* */
|
||||
External(
|
||||
id = "debug_beta",
|
||||
appIdSuffix = "debug",
|
||||
versionSuffix = "debug",
|
||||
configFields = listOf(
|
||||
BuildConfigField.Environment(value = "prod"),
|
||||
BuildConfigField.TestActionEnabled(isEnabled = true),
|
||||
BuildConfigField.LogEnabled(isEnabled = false),
|
||||
BuildConfigField.TesterMenuAvailability(isEnabled = true),
|
||||
),
|
||||
),
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue