Created
December 24, 2019 17:18
-
-
Save fleficher/ccf118de16383c5333397298f55f50a4 to your computer and use it in GitHub Desktop.
build config fields KTX
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
// For flavors usage | |
fun BaseFlavor.buildConfigBoolean(name: String, value: Boolean) = | |
buildConfigField("Boolean", name, value.toString()) | |
fun BaseFlavor.buildConfigString(name: String, value: String) = | |
buildConfigField("String", name, "\"$value\"") | |
// For build types usage | |
fun BuildType.buildConfigString(name: String, value: String) = | |
buildConfigField("String", name, "\"$value\"") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment