build: inline versionCode and versionName at destination

Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
Harsh Shandilya
2020-04-21 13:54:24 +05:30
parent e6ea5f6a08
commit 3d0850fa1f
3 changed files with 3 additions and 6 deletions

View File

@@ -26,7 +26,7 @@ android {
if (isSnapshot()) { if (isSnapshot()) {
android.applicationVariants.all { final variant -> android.applicationVariants.all { final variant ->
variant.outputs.all { variant.outputs.all {
outputFileName = "aps_${versions.versionName}.apk" outputFileName = "aps_${defaultConfig.versionName}.apk"
} }
} }
} }
@@ -35,6 +35,8 @@ android {
defaultConfig { defaultConfig {
applicationId versions.packageName applicationId versions.packageName
versionCode 10601
versionName '1.7.0-SNAPSHOT'
} }
lintOptions { lintOptions {

View File

@@ -48,9 +48,6 @@ subprojects {
defaultConfig { defaultConfig {
minSdkVersion versions.minSdk minSdkVersion versions.minSdk
targetSdkVersion versions.targetSdk targetSdkVersion versions.targetSdk
versionCode versions.versionCode
versionName versions.versionName
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
} }
compileOptions { compileOptions {

View File

@@ -6,8 +6,6 @@ ext.versions = [
minSdk: 23, minSdk: 23,
targetSdk: 29, targetSdk: 29,
compileSdk: 29, compileSdk: 29,
versionCode: 10601,
versionName: '1.7.0-SNAPSHOT',
buildTools: '29.0.3', buildTools: '29.0.3',
packageName: 'dev.msfjarvis.aps' packageName: 'dev.msfjarvis.aps'
] ]