-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
82 lines (68 loc) · 2.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
buildscript {
ext.kotlin_version = '1.3.20'
repositories {
jcenter()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
ext {
minSdkVersion = 16
targetSdkVersion = 27
compileSdkVersion = 28
buildToolsVersion = '28.0.3'
deps = [:]
deps.versions = [
support: '28.0.0'
]
deps.app = [
support : [
appcompat : "com.android.support:appcompat-v7:${deps.versions.support}",
annotations: "com.android.support:support-annotations:${deps.versions.support}"
],
rxjava : 'io.reactivex.rxjava2:rxjava:2.1.9',
rxandroid: 'io.reactivex.rxjava2:rxandroid:2.0.1',
rxkotlin : 'io.reactivex.rxjava2:rxkotlin:2.3.0'
]
deps.test = [
junit : 'junit:junit:4.12',
mockito_kotlin: 'com.nhaarman.mockitokotlin2:mockito-kotlin:2.1.0',
assertj : 'org.assertj:assertj-core:3.11.1'
]
}
allprojects {
repositories {
google()
jcenter()
}
}
subprojects { subproject ->
plugins.whenPluginAdded { plugin ->
def isAppPlugin = (plugin.class.name == 'com.android.build.gradle.AppPlugin')
def isLibraryPlugin = (plugin.class.name == 'com.android.build.gradle.LibraryPlugin')
def isTestPlugin = (plugin.class.name == 'com.android.build.gradle.TestPlugin')
def isAndroidPlugin = isAppPlugin || isLibraryPlugin || isTestPlugin
if (isAndroidPlugin) {
subproject.apply plugin: 'kotlin-android-extensions'
subproject.apply plugin: 'kotlin-android'
android {
androidExtensions {
experimental = true
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}