Created
June 26, 2021 09:33
-
-
Save aashutoshrathi/2efbf4254aa981850c909a3ef0d7b591 to your computer and use it in GitHub Desktop.
Force Same Version Code/ Build Number to all variant APKs using Flutter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
android { | |
... | |
} | |
// Add the below code in android/app/build.gradle after above android block | |
// Provide same version code to all! | |
import com.android.build.OutputFile | |
android.applicationVariants.all { variant -> | |
variant.outputs.each { output -> | |
output.versionCodeOverride = flutterVersionCode.toInteger() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment