-
-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Describe the bug
Changing flavor does not reflect in app on first build.
To Reproduce
If you have a build konfig that looks like this:
defaultConfigs() {
buildConfigField(FieldSpec.Type.STRING, "FLAVOR", "local")
}
defaultConfigs("stage") {
buildConfigField(FieldSpec.Type.STRING, "FLAVOR", "stage")
}
defaultConfigs("prod") {
buildConfigField(FieldSpec.Type.STRING, "FLAVOR", "prod")
}
// App Code
val flavor = BuildKonfig.FLAVOR // Breakpoint here
If you update flavor in gradle.properties + sync + debug app, the flavor is going to be the previous gradle.properties value is initally but updated on the second run.
Something weird here is that the BuildKonfig.FLAVOR is updated if i go to the source file but the breakpoint's value is the old one.
Expected behavior
Changing gradle.properties + sync + build should result in BuildKonfig.FLAVOR to be matching the gradle config for the gradle.properties file.
- BuildKonfig Version 0.17.0
- Kotlin Version 2.1.20
- Gradle Version 8.9
Metadata
Metadata
Assignees
Labels
No labels