-
Notifications
You must be signed in to change notification settings - Fork 216
Expand file tree
/
Copy pathbuild.gradle
More file actions
102 lines (86 loc) · 2.5 KB
/
build.gradle
File metadata and controls
102 lines (86 loc) · 2.5 KB
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
buildscript {
ext.kotlinVersion = '1.4.0'
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.0.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
}
}
ext {
// From e.g. https://source.android.com/setup/start/build-numbers
// Android 10 29 Q
// Android 9.0 28 PIE
// Android 8.1 27 OREO_MR1
// Android 8.0 26 OREO
// Android 7.1.1, 7.1 25 NOUGAT_MR1
// Android 7.0 24 NOUGAT
// Android 6.0 23 MARSHMALLOW
// Android 5.1 22 LOLLIPOP_MR1
// Android 5.0 21 LOLLIPOP
// Android 4.4W 20 KITKAT_WATCH
// Android 4.4 19 KITKAT
// Android 4.3 18 JELLY_BEAN_MR2
// Android 4.2, 4.2.2 17 JELLY_BEAN_MR1
// Remember to keep these values in sync with .travis.yml
compileSdkVersion=29
minSdkVersion=23
targetSdkVersion=29
buildToolsVersion='29.0.3'
// centrally manage some other dependencies
mapsforgeVersion = '0.14.0'
osmdroidVersion = '6.1.6'
// test dependencies
assertjVersion = '3.15.0'
junitVersion = '4.13'
mockitoVersion = '2.28.2'
robolectricVersion = '4.3.1'
}
// Configure common settings in all projects
subprojects {
if (!file("${projectDir}/build.gradle").exists())
return
gradle.projectsEvaluated {
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
}
buildscript {
repositories {
google()
jcenter()
}
}
repositories {
google()
jcenter()
maven { url "https://jitpack.io" }
}
if (projectDir.getName().equals('cyclestreets.app')) {
apply plugin: 'com.android.application'
} else {
apply plugin: 'com.android.library'
}
apply plugin: 'kotlin-android'
android {
compileSdkVersion rootProject.ext.compileSdkVersion
buildToolsVersion rootProject.ext.buildToolsVersion
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
defaultConfig {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
}
lintOptions {
// Required due to strictness of the Android developer tools. See lint.xml for full details.
lintConfig rootProject.file('gradle/lint.xml')
// Kotlin (nullability) interop check - potentially useful but quite noisy
// check 'Interoperability'
}
buildFeatures.viewBinding = true
}
}