-
Notifications
You must be signed in to change notification settings - Fork 50
/
build.gradle
84 lines (74 loc) · 2.15 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
apply plugin: 'com.github.ben-manes.versions'
buildscript {
ext.versions = [
'minSdk': 21,
'targetSdk': 30,
'agp': '7.0.0',
'lint': '30.0.0', // = 23.0.0 + agp
'kotlin': '1.5.10',
'autoService': '1.0',
]
ext.deps = [
'androidx': [
'appCompat': 'androidx.appcompat:appcompat:1.3.1',
'ktx': 'androidx.core:core-ktx:1.6.0',
'transition': 'androidx.transition:transition:1.4.1',
],
'picasso': 'com.squareup.picasso:picasso:2.8',
'lint': [
'api': "com.android.tools.lint:lint-api:${versions.lint}",
'lint': "com.android.tools.lint:lint:${versions.lint}",
'tests': "com.android.tools.lint:lint-tests:${versions.lint}",
],
'auto': [
'service': "com.google.auto.service:auto-service:${versions.autoService}",
'serviceAnnotations': "com.google.auto.service:auto-service-annotations:${versions.autoService}",
],
'junit': 'junit:junit:4.13.2',
'robolectric': 'org.robolectric:robolectric:4.6.1',
'truth': 'com.google.truth:truth:1.1.3',
'plugins': [
'agp': "com.android.tools.build:gradle:${versions.agp}",
'kotlin': "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
],
]
dependencies {
classpath deps.plugins.agp
classpath deps.plugins.kotlin
classpath 'com.github.ben-manes:gradle-versions-plugin:0.39.0'
classpath 'com.vanniktech:gradle-maven-publish-plugin:0.17.0'
}
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}
subprojects {
repositories {
google()
mavenCentral()
}
tasks.withType(JavaCompile).configureEach { task ->
task.sourceCompatibility = JavaVersion.VERSION_1_8
task.targetCompatibility = JavaVersion.VERSION_1_8
}
tasks.withType(org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompile).configureEach { task ->
task.kotlinOptions {
jvmTarget = "1.8"
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
subprojects { project ->
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
kotlinOptions {
jvmTarget = "1.8"
}
}
}
tasks.wrapper {
distributionType = Wrapper.DistributionType.BIN
}