1
+ plugins {
2
+ id ' com.google.devtools.ksp' version ' 1.7.10-1.0.6'
3
+ }
4
+
1
5
apply plugin : ' com.android.application'
2
6
apply plugin : ' kotlin-android'
3
7
apply plugin : ' kotlin-kapt'
4
- apply plugin : " androidx.navigation.safeargs.kotlin "
8
+ apply plugin : " androidx.navigation.safeargs"
5
9
apply plugin : ' com.google.firebase.crashlytics'
6
10
apply plugin : ' com.google.gms.google-services'
7
11
apply plugin : ' dagger.hilt.android.plugin'
8
- apply plugin : ' com.mikepenz.aboutlibraries.plugin'
9
12
apply plugin : ' com.google.firebase.firebase-perf'
10
13
apply plugin : ' com.github.triplet.play'
14
+ apply plugin : ' com.dicedmelon.gradle.jacoco-android'
11
15
12
16
android {
13
17
compileSdkVersion Config . compile_sdk
14
- buildToolsVersion Config . build_tools
15
18
16
19
defaultConfig {
17
20
applicationId " de.psdev.devdrawer"
@@ -22,16 +25,20 @@ android {
22
25
23
26
testInstrumentationRunner " androidx.test.runner.AndroidJUnitRunner"
24
27
multiDexEnabled true
25
-
26
- resConfig " en"
28
+ resConfigs ' en'
27
29
28
30
// Version info
29
31
buildConfigField ' String' , ' GIT_SHA' , " \" ${ project.ext.gitHash} \" "
30
32
33
+ vectorDrawables {
34
+ useSupportLibrary true
35
+ }
36
+
31
37
javaCompileOptions. annotationProcessorOptions. arguments[' room.schemaLocation' ] = rootProject. file(' schemas' ). toString()
32
38
}
33
39
buildFeatures {
34
40
viewBinding true
41
+ compose true
35
42
}
36
43
compileOptions {
37
44
sourceCompatibility = JavaVersion . VERSION_1_8
@@ -41,11 +48,15 @@ android {
41
48
jvmTarget = " 1.8"
42
49
freeCompilerArgs + = [
43
50
" -Xinline-classes" ,
44
- " -Xopt-in=kotlin.RequiresOptIn" ,
45
- " -Xopt-in=kotlin.ExperimentalStdlibApi" ,
46
- " -Xopt-in=kotlin.time.ExperimentalTime" ,
47
- " -Xopt-in=kotlinx.coroutines.FlowPreview" ,
48
- " -Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi"
51
+ " -Xjvm-default=all" ,
52
+ " -opt-in=kotlin.RequiresOptIn" ,
53
+ " -opt-in=kotlin.ExperimentalStdlibApi" ,
54
+ " -opt-in=kotlin.time.ExperimentalTime" ,
55
+ " -opt-in=kotlinx.coroutines.FlowPreview" ,
56
+ " -opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi" ,
57
+ " -opt-in=androidx.compose.foundation.ExperimentalFoundationApi" ,
58
+ " -opt-in=androidx.compose.animation.ExperimentalAnimationApi" ,
59
+ " -opt-in=androidx.compose.material.ExperimentalMaterialApi"
49
60
]
50
61
}
51
62
testOptions {
@@ -92,18 +103,25 @@ android {
92
103
}
93
104
}
94
105
}
95
- lintOptions {
96
- lintConfig project. file(' lint.xml' )
97
- disable " GoogleAppIndexingWarning"
98
- disable " RemoveWorkManagerInitializer"
106
+ packagingOptions {
107
+ resources {
108
+ excludes + = [' **/LICENSE' , ' **/LICENSE.txt' , ' **/NOTICE' , ' **/NOTICE.txt' , ' **/*.gwt.xml' ]
109
+ }
110
+ }
111
+ composeOptions {
112
+ kotlinCompilerExtensionVersion Versions . androidXComposeCompiler
113
+ }
114
+ lint {
115
+ disable ' GoogleAppIndexingWarning' , ' RemoveWorkManagerInitializer'
99
116
enable ' Interoperability'
117
+ lintConfig file(' lint.xml' )
100
118
}
101
- packagingOptions {
102
- exclude ' **/LICENSE '
103
- exclude ' **/LICENSE.txt '
104
- exclude ' **/NOTICE '
105
- exclude ' **/NOTICE.txt '
106
- exclude ' **/*.gwt.xml '
119
+ applicationVariants . all { variant ->
120
+ kotlin . sourceSets {
121
+ getByName(variant . name) {
122
+ kotlin . srcDir( " build/generated/ksp/ ${ variant.name } /kotlin " )
123
+ }
124
+ }
107
125
}
108
126
}
109
127
@@ -133,30 +151,49 @@ dependencies {
133
151
implementation Libs . androidx_browser
134
152
implementation Libs . androidx_constraint_layout
135
153
implementation Libs . androidx_core
154
+ implementation " androidx.core:core-splashscreen:1.0.0"
136
155
implementation Libs . androidx_fragment
137
156
implementation Libs . androidx_hilt_work
138
157
implementation Libs . androidx_lifecycle_viewmodel
158
+ implementation Libs . androidx_lifecycle_livedata
139
159
implementation Libs . androidx_lifecycle_java8
160
+ implementation Libs . androidx_lifecycle_runtime
140
161
implementation Libs . androidx_lifecycle_process
141
162
implementation Libs . androidx_navigation_fragment
142
163
implementation Libs . androidx_navigation_ui
164
+ implementation " androidx.navigation:navigation-compose:$Versions . androidXNavigation "
143
165
implementation Libs . androidx_preference
144
166
implementation Libs . androidx_recyclerview
145
167
implementation Libs . androidx_recyclerview_selection
146
168
implementation Libs . androidx_room_runtime
147
169
implementation Libs . androidx_room_ktx
148
170
implementation Libs . androidx_work_runtime
149
171
implementation Libs . androidx_work_gcm
172
+ implementation ' androidx.activity:activity-compose:1.5.1'
173
+ implementation " androidx.compose.ui:ui:$Versions . androidXCompose "
174
+ implementation " androidx.compose.foundation:foundation:$Versions . androidXCompose "
175
+ implementation " androidx.compose.material:material:$Versions . androidXCompose "
176
+ implementation " androidx.compose.material:material-icons-core:$Versions . androidXCompose "
177
+ implementation " androidx.compose.material:material-icons-extended:$Versions . androidXCompose "
178
+ implementation " androidx.compose.ui:ui-tooling:$Versions . androidXCompose "
179
+
180
+ implementation " androidx.lifecycle:lifecycle-viewmodel-compose:$Versions . androidXLifecycle "
181
+ implementation ' androidx.hilt:hilt-navigation-compose:1.0.0'
182
+ androidTestImplementation " androidx.compose.ui:ui-test-junit4:$Versions . androidXCompose "
150
183
kapt Libs . androidx_room_compiler
151
184
kapt Libs . androidx_hilt_compiler
152
185
153
186
// Android Material
154
187
implementation Libs . material_components
155
188
156
189
// Color Picker
157
- implementation " com.github.dhaval2404:colorpicker:2.0 "
190
+ implementation " com.github.dhaval2404:colorpicker:2.3 "
158
191
159
- // Dagger
192
+ // Compose Destinations
193
+ implementation ' io.github.raamcosta.compose-destinations:core:1.6.15-beta'
194
+ ksp ' io.github.raamcosta.compose-destinations:ksp:1.6.15-beta'
195
+
196
+ // Dagger
160
197
implementation Libs . daggerHiltAndroid
161
198
kapt Libs . daggerHiltAndroidCompiler
162
199
@@ -182,8 +219,8 @@ dependencies {
182
219
implementation Libs . kotlinCoroutinesAndroid
183
220
184
221
// LeakCanary
185
- debugImplementation Libs . leakCanary
186
- implementation Libs . leakCanaryPlumberAndroid
222
+ // debugImplementation Libs.leakCanary
223
+ // implementation Libs.leakCanaryPlumberAndroid
187
224
188
225
// Logging
189
226
implementation Libs . slf4jAndroidLogger
@@ -200,6 +237,10 @@ kapt {
200
237
correctErrorTypes true
201
238
}
202
239
240
+ jacoco {
241
+ toolVersion = " 0.8.7"
242
+ }
243
+
203
244
play {
204
245
def serviceAccountFileName = " google-play-api.json"
205
246
if (rootProject. file(serviceAccountFileName). exists()) {
0 commit comments