-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
105 lines (90 loc) · 2.86 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
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext.kotlin_version = "1.6.10"
ext {
ktx = '1.7.0'
app_compat = '1.4.1'
google_material = '1.5.0'
constraint_layout = '2.1.3'
annotation = '1.3.0'
exif_interface = "1.1.0"
pallete = "1.0.0"
fragment = '1.4.1'
swipe_refresh = '1.1.0'
arch = "2.1.0"
view_pager = "1.0.0"
preference = '1.2.0'
// Architecture
room = '2.4.1'
lifecycle = '2.4.1'
paging = '3.1.0'
navigation = '2.4.1'
work_manager = '2.7.1'
// Dependency Injection
dagger = '2.40.5'
hilt_dagger = '2.40.5'
// Logs
timber = "5.0.1"
// Image
glide = '4.12.0'
lottie = '3.3.1'
// Networking
okhttp = '4.9.2'
retrofit = '2.9.0'
// Others
gson = '2.8.9'
// Build Versions
android_gradle_plugin = '7.1.1'
}
repositories {
google()
maven { url "https://plugins.gradle.org/m2/" }
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
}
dependencies {
classpath "com.android.tools.build:gradle:$android_gradle_plugin"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:$navigation"
classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_dagger"
classpath 'com.google.gms:google-services:4.3.10'
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.8.1'
}
}
plugins {
id 'com.diffplug.spotless' version '5.13.0'
}
allprojects {
repositories {
google()
maven { url "https://plugins.gradle.org/m2/" }
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
maven { url "https://jitpack.io" }
}
}
subprojects {
// apply plugin: 'com.diffplug.spotless'
// spotless {
// kotlin {
// target '**/*.kt'
// targetExclude("$buildDir/**/*.kt")
// targetExclude('bin/**/*.kt')
//
// ktlint("0.42.0")
// }
// }
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
kotlinOptions {
// Treat all Kotlin warnings as errors
// allWarningsAsErrors = true
// Enable experimental coroutines APIs, including Flow
freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi"
freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.FlowPreview"
freeCompilerArgs += "-Xopt-in=kotlin.Experimental"
// Set JVM target to 1.8
jvmTarget = "1.8"
}
}
}
task cleanEverything(type: Delete) {
delete rootProject.buildDir
}