-
Notifications
You must be signed in to change notification settings - Fork 21
/
build.gradle
141 lines (128 loc) · 5.23 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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
/*
* Copyright (C) 2016 Jorge Ruesga
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
ext {
libraries = [
androidx_appcompat : '1.1.0',
androidx_browser : '1.2.0',
androidx_cardview : '1.0.0',
androidx_exifinterface : '1.2.0',
androidx_legacy : '1.0.0',
material : '1.1.0',
play_services_auth : '18.0.0',
firebase_core : '17.4.1',
firebase_messaging : '20.1.7',
firebase_crashlytics : '17.0.0',
gson : '2.8.6',
retrofit2 : '2.8.1',
// Keep okHttp in 3.12.x, since 3.13+ requires Android 5
okhttp3 : '3.12.10',
okio : '2.5.0',
okhttp_digest : 'f13c5b8f79',
rxjava : '2.2.19',
rxandroid : '2.1.1',
rxloader2 : 'edeebf0a1a',
// Keep commons-io in 2.5. Prior android versions doesn't have fully support for Files api.
commons_io : '2.5',
antlrv3 : '3.5.2',
smoothprogressbar : '1.1.0',
glide : '4.11.0',
prettytime : '4.0.5.Final',
flexboxlayout : '2.0.1',
floatingsearchview : '2d435bead5',
androidsvg : '3511e13649',
keyboardvisibilityevent : '2.3.0',
better_link_movement_method : '2.2.0',
aboutlibraries : '8.1.2',
aboutlibraries_definitions : '8.1.0'
]
testLibraries = [
junit : '4.13',
hamcrest : '2.2',
mockito : '3.3.3',
powermock : '2.0.7',
robolectric : '4.3.1',
base64 : '2.3.9'
]
}
allprojects {
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.6.3'
classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:1.0.2'
}
}
repositories {
google()
jcenter()
maven { url "https://jitpack.io" }
}
gradle.projectsEvaluated {
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
}
}
subprojects {
afterEvaluate {project ->
dependencies {
testImplementation "junit:junit:${testLibraries.junit}"
testImplementation "org.hamcrest:hamcrest-core:${testLibraries.hamcrest}"
testImplementation "org.hamcrest:hamcrest-library:${testLibraries.hamcrest}"
testImplementation "org.mockito:mockito-core:${testLibraries.mockito}"
testImplementation "org.powermock:powermock-module-junit4:${testLibraries.powermock}"
testImplementation "org.powermock:powermock-module-junit4-rule:${testLibraries.powermock}"
testImplementation "org.powermock:powermock-api-mockito2:${testLibraries.powermock}"
testImplementation "org.robolectric:robolectric:${testLibraries.robolectric}"
}
if (project.plugins.hasPlugin('android') || project.plugins.hasPlugin('android-library')) {
android {
compileSdkVersion 29
// https://developer.android.com/studio/releases/build-tools.html
buildToolsVersion '29.0.3'
defaultConfig {
minSdkVersion 16
targetSdkVersion 29
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/rxjava.properties'
}
testOptions.unitTests.includeAndroidResources = true
testOptions {
unitTests.all {
testLogging {
events "passed", "skipped", "failed", "standardError"
outputs.upToDateWhen {false}
}
}
}
}
}
}
}