-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
117 lines (96 loc) · 3.62 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
buildscript {
repositories {
jcenter()
google()
}
// Kotlin
ext.kotlinVersion = '1.3.71'
dependencies {
classpath 'com.android.tools.build:gradle:3.6.3'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.8.2'
}
ext {
// local variables (use def)
def coroutines_android_version = '1.3.2'
def lifecycle_version = '2.1.0'
def livedata_version = '2.2.0-rc02'
def koin_version = '2.0.1'
def room_version = '2.2.3'
def junit_version = '4.12'
def mockito_kotlin_version = '2.2.0'
def truth_version = '1.0'
def androidx_test_version = '1.2.0'
def androidx_test_ext_version = '1.1.1'
def expresso_version = '3.2.0'
libraries = [
// Coroutines
"org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_android_version",
"org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines_android_version",
// ViewModel and LiveData
"androidx.lifecycle:lifecycle-extensions:$lifecycle_version",
"androidx.lifecycle:lifecycle-livedata-ktx:$livedata_version",
"androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version",
// Koin for DI
"org.koin:koin-android:$koin_version",
"org.koin:koin-android-viewmodel:$koin_version",
// Room for database
"androidx.room:room-ktx:$room_version",
]
librariesKapt = [
"androidx.room:room-compiler:$room_version",
]
testLibraries = [
"junit:junit:$junit_version",
// Coroutines testing
"org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines_android_version",
// mocks
"com.nhaarman.mockitokotlin2:mockito-kotlin:$mockito_kotlin_version",
// Architecture Components testing libraries
"androidx.arch.core:core-testing:$lifecycle_version",
"com.google.truth:truth:$truth_version",
]
androidTestLibraries = [
"junit:junit:$junit_version",
"androidx.test:runner:$androidx_test_version",
"androidx.test:rules:$androidx_test_version",
"androidx.test.ext:junit:$androidx_test_ext_version",
// Espresso
"androidx.test.espresso:espresso-core:$expresso_version",
"androidx.test.espresso:espresso-contrib:$expresso_version",
"androidx.test.espresso:espresso-intents:$expresso_version",
// Architecture Components testing libraries
"androidx.arch.core:core-testing:$lifecycle_version",
// Coroutines testing
"org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines_android_version",
]
}
}
allprojects {
repositories {
jcenter()
google()
maven { url "https://jitpack.io" }
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
ext {
// Sdk and tools
minSdkVersion = 19
targetSdkVersion = 28
compileSdkVersion = 28
// App dependencies
appcompatVersion = '1.1.0'
materialVersion = '1.1.0'
recyclerViewVersion = '1.1.0'
swipeRefreshLayoutVersion = '1.0.0'
ktxVersion = '1.2.0'
kAndroidVersion = '0.6.15'
androidJoda = '2.9.9.1'
okHttpVersion = '3.9.1'
retrofitVersion = '2.7.1'
// Testing dependencies
testVersion = '1.2.0'
}