Skip to content

Commit

Permalink
read project vars for compileSdkVersion, buildToolsVersion,
Browse files Browse the repository at this point in the history
`targetSdkVersion`
  • Loading branch information
abonander committed Mar 7, 2019
1 parent 8d2bc78 commit f22fd9a
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,17 @@ buildscript {

apply plugin: 'com.android.library'

def projectVar(name, fallback) {
return project.findProperty(name) ?: fallback
}

android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
compileSdkVersion projectVar('compileSdkVersion', 27)
buildToolsVersion projectVar('buildToolsVersion', '27.0.3')

defaultConfig {
minSdkVersion 16
targetSdkVersion 22
targetSdkVersion projectVar('targetSdkVersion', 27)
versionCode 1
versionName "1.0"
}
Expand Down

0 comments on commit f22fd9a

Please sign in to comment.