Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save minakov/db3e546a6c9b4de595a5 to your computer and use it in GitHub Desktop.

Select an option

Save minakov/db3e546a6c9b4de595a5 to your computer and use it in GitHub Desktop.
android {
applicationVariants.all { variant ->
def flavor = variant.mergedFlavor
def name = flavor.getVersionName()
def versionName = name + '-' + variant.properties.get('flavorName')
if (variant.buildType.isDebuggable()) {
versionName += '-debug';
}
flavor.versionName = versionName;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment