forked from square/spoon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
97 lines (85 loc) · 3.09 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
buildscript {
ext.versions = [
'minSdk': 9,
'compileSdk': 25,
'buildTools': '26.0.2',
'supportLibrary': '25.3.1',
'kotlin': '1.1.2',
'errorProne': '2.0.19',
]
ext.deps = [
'gson': 'com.google.code.gson:gson:2.8.0',
'argparser': 'com.xenomachina:kotlin-argparser:2.0.0',
'commonsLang3': 'org.apache.commons:commons-lang3:3.3.1',
'commonsIo': 'commons-io:commons-io:2.5',
'ddmlib': 'com.android.tools.ddms:ddmlib:25.3.0',
'animatedGifLib': 'com.madgag:animated-gif-lib:1.2',
'guava': 'com.google.guava:guava:21.0',
'lesscss': 'org.lesscss:lesscss:1.3.3',
'mustache': 'com.github.spullara.mustache.java:compiler:0.8.14',
'jacocoMavenPlugin': 'org.jacoco:jacoco-maven-plugin:0.7.6.201602180812',
'butterknife': [
'runtime': 'com.jakewharton:butterknife:8.5.1',
'compiler': 'com.jakewharton:butterknife-compiler:8.5.1'
],
'kotlinStdLibJre8': "org.jetbrains.kotlin:kotlin-stdlib-jre8:${versions.kotlin}",
'junit': 'junit:junit:4.12',
'truth': 'com.google.truth:truth:0.31',
'support': [
'annotations': "com.android.support:support-annotations:${versions.supportLibrary}",
'appCompat': "com.android.support:appcompat-v7:${versions.supportLibrary}",
'design': "com.android.support:design:${versions.supportLibrary}",
'constraintLayout': "com.android.support.constraint:constraint-layout:1.0.2",
'test': [
'espresso': 'com.android.support.test.espresso:espresso-core:2.2.2',
'espressoContrib': 'com.android.support.test.espresso:espresso-contrib:2.2.2',
'runner': 'com.android.support.test:runner:0.5',
'rules': 'com.android.support.test:rules:0.5',
],
],
]
dependencies {
classpath 'com.android.tools.build:gradle:3.0.0-beta7'
classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.4'
classpath 'net.ltgt.gradle:gradle-errorprone-plugin:0.0.10'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
}
repositories {
google()
jcenter()
maven {
url 'https://plugins.gradle.org/m2/'
}
}
}
subprojects { project ->
group = GROUP
version = VERSION_NAME
repositories {
google()
jcenter()
}
apply plugin: 'checkstyle'
project.checkstyle {
toolVersion "7.6.1"
configFile rootProject.file('checkstyle.xml')
}
if (!project.path.startsWith(':third-party')) {
project.apply(plugin: 'net.ltgt.errorprone')
}
configurations.all {
resolutionStrategy {
eachDependency { details ->
// Force all of the primary support libraries to use the same version.
if (details.requested.group == 'com.android.support') {
details.useVersion versions.supportLibrary
}
// Force all the error-prone dependencies to use the same version.
if (details.requested.group == 'com.google.errorprone'
&& details.requested.name.startsWith('error_prone_')) {
details.useVersion versions.errorProne
}
}
}
}
}