Skip to content

Commit a42aef1

Browse files
committed
Updated library and sample app to get version numbers from root project
1 parent 07a226d commit a42aef1

File tree

3 files changed

+22
-14
lines changed

3 files changed

+22
-14
lines changed

app/build.gradle

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@ apply plugin: 'com.android.application'
1313
apply plugin: 'spoon'
1414

1515
android {
16-
compileSdkVersion 24
17-
buildToolsVersion "24.0.0"
16+
compileSdkVersion compileSdkVer
17+
buildToolsVersion buildToolsVer
1818

1919
defaultConfig {
2020
applicationId "com.stealthcotper.networktools"
21-
minSdkVersion 14
22-
targetSdkVersion 24
23-
versionCode 5
24-
versionName "0.1.06"
21+
minSdkVersion minSdkVer
22+
targetSdkVersion targetSdkVer
23+
versionCode 6
24+
versionName "0.1.08"
2525
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
2626
}
2727
buildTypes {
@@ -48,8 +48,8 @@ spoon {
4848

4949
dependencies {
5050
compile fileTree(dir: 'libs', include: ['*.jar'])
51-
compile 'com.android.support:appcompat-v7:24.2.0'
52-
compile 'com.android.support:design:24.2.0'
51+
compile "com.android.support:appcompat-v7:$supportLibVer"
52+
compile "com.android.support:design:$supportLibVer"
5353
compile project(':library')
5454

5555
testCompile 'junit:junit:4.12'

build.gradle

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,11 @@ allprojects {
2121
task clean(type: Delete) {
2222
delete rootProject.buildDir
2323
}
24+
25+
subprojects {
26+
ext.compileSdkVer = 24
27+
ext.buildToolsVer = "24.0.0"
28+
ext.minSdkVer = 10
29+
ext.targetSdkVer = 24
30+
ext.supportLibVer = "24.0.0"
31+
}

library/build.gradle

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
apply plugin: 'com.android.library'
22

33
android {
4-
compileSdkVersion 24
5-
buildToolsVersion "24.0.0"
4+
compileSdkVersion compileSdkVer
5+
buildToolsVersion buildToolsVer
66

77
defaultConfig {
8-
minSdkVersion 14
9-
targetSdkVersion 24
10-
versionCode 2
11-
versionName "0.1.3"
8+
minSdkVersion minSdkVer
9+
targetSdkVersion targetSdkVer
10+
versionCode 3
11+
versionName "0.2.0"
1212
}
1313
buildTypes {
1414
release {

0 commit comments

Comments
 (0)