Skip to content

Commit 98e110c

Browse files
committed
Updates the build flavor examples
1 parent a27da2f commit 98e110c

File tree

8 files changed

+19
-16
lines changed

8 files changed

+19
-16
lines changed

com.vogella.android.gradlebuildflavors/app/build.gradle

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

33
android {
4-
compileSdkVersion 22
5-
buildToolsVersion "23.0.0"
4+
compileSdkVersion 23
5+
buildToolsVersion "23.0.3"
66

77
lintOptions {
88
abortOnError false
@@ -22,14 +22,15 @@ android {
2222
}
2323
}
2424
productFlavors {
25-
paid {
26-
applicationId = "com.vogella.android.paid"
25+
prod {
26+
applicationId = "com.vogella.android.gradlebuildflavors.prod"
27+
versionName = "1.0-paid"
2728
}
2829

29-
free {
30-
applicationId = "com.vogella.android.free"
30+
mock {
31+
applicationId = "com.vogella.android.gradlebuildflavors.mock"
32+
versionName = "1.0-free"
3133
}
32-
3334
}
3435

3536
}

com.vogella.android.gradlebuildflavors/app/src/free/res/values/strings.xml

Lines changed: 0 additions & 6 deletions
This file was deleted.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<resources>
2+
<string name="app_name">Flavor</string>
3+
<string name="hello_world">Mock World! </string>
4+
</resources>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<resources>
2+
<string name="app_name">Flavor</string>
3+
<string name="hello_world">Prod World! </string>
4+
</resources>

com.vogella.android.gradlebuildflavors/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ buildscript {
55
jcenter()
66
}
77
dependencies {
8-
classpath 'com.android.tools.build:gradle:1.3.0'
8+
classpath 'com.android.tools.build:gradle:2.2.0-alpha3'
99

1010
// NOTE: Do not place your application dependencies here; they belong
1111
// in the individual module build.gradle files
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#Mon Jul 20 08:46:03 CEST 2015
1+
#Sat Jun 18 13:35:24 CEST 2016
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip

0 commit comments

Comments
 (0)