@@ -120,13 +120,12 @@ android {
120
120
}
121
121
}
122
122
}
123
-
124
123
compileOptions {
125
- sourceCompatibility(JavaVersion .VERSION_11 )
126
- targetCompatibility(JavaVersion .VERSION_11 )
124
+ sourceCompatibility(JavaVersion .VERSION_17 )
125
+ targetCompatibility(JavaVersion .VERSION_17 )
127
126
}
128
127
kotlinOptions {
129
- jvmTarget = " 11 "
128
+ jvmTarget = JavaVersion . VERSION_17 .toString()
130
129
// freeCompilerArgs = listOf("-Xallow-result-return-type")
131
130
}
132
131
// https://developer.android.com/topic/libraries/data-binding
@@ -135,7 +134,7 @@ android {
135
134
compose = true
136
135
}
137
136
composeOptions {
138
- kotlinCompilerExtensionVersion = " 1.4.0 "
137
+ kotlinCompilerExtensionVersion = " 1.4.1 "
139
138
}
140
139
lint {
141
140
checkReleaseBuilds = false
@@ -150,32 +149,32 @@ dependencies {
150
149
implementation(" androidx.constraintlayout:constraintlayout:2.1.4" )
151
150
implementation(" androidx.recyclerview:recyclerview:1.3.0" )
152
151
implementation(" com.google.android.material:material:1.8.0" )
153
- implementation(" org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.10 " )
154
- implementation(" org.jetbrains.kotlin:kotlin-reflect:1.8.0 " )
152
+ implementation(" org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.20 " )
153
+ implementation(" org.jetbrains.kotlin:kotlin-reflect:1.8.20 " )
155
154
implementation(" androidx.multidex:multidex:2.0.1" )
156
155
157
156
// List of KTX extensions
158
157
// https://developer.android.com/kotlin/ktx/extensions-list
159
- implementation(" androidx.core:core-ktx:1.9 .0" )
160
- implementation(" androidx.activity:activity-ktx:1.6.1 " )
161
- implementation(" androidx.fragment:fragment-ktx:1.5.5 " )
158
+ implementation(" androidx.core:core-ktx:1.10 .0" )
159
+ implementation(" androidx.activity:activity-ktx:1.7.0 " )
160
+ implementation(" androidx.fragment:fragment-ktx:1.5.6 " )
162
161
163
162
// Lifecycle
164
163
// https://developer.android.com/jetpack/androidx/releases/lifecycle
165
- implementation(" androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.0 " )
166
- implementation(" androidx.lifecycle:lifecycle-livedata-ktx:2.6.0 " )
167
- implementation(" androidx.lifecycle:lifecycle-runtime-ktx:2.6.0 " )
168
- implementation(" androidx.lifecycle:lifecycle-common-java8:2.6.0 " )
164
+ implementation(" androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.1 " )
165
+ implementation(" androidx.lifecycle:lifecycle-livedata-ktx:2.6.1 " )
166
+ implementation(" androidx.lifecycle:lifecycle-runtime-ktx:2.6.1 " )
167
+ implementation(" androidx.lifecycle:lifecycle-common-java8:2.6.1 " )
169
168
170
169
// Preferences DataStore
171
170
// https://android-developers.googleblog.com/2020/09/prefer-storing-data-with-jetpack.html
172
171
implementation(" androidx.datastore:datastore-preferences:1.0.0" )
173
172
174
173
// room
175
174
// https://developer.android.com/topic/libraries/architecture/room
176
- implementation(" androidx.room:room-runtime:2.5.0 " )
177
- kapt(" androidx.room:room-compiler:2.5.0 " )
178
- implementation(" androidx.room:room-ktx:2.5.0 " )
175
+ implementation(" androidx.room:room-runtime:2.5.1 " )
176
+ kapt(" androidx.room:room-compiler:2.5.1 " )
177
+ implementation(" androidx.room:room-ktx:2.5.1 " )
179
178
180
179
// paging
181
180
// https://developer.android.com/topic/libraries/architecture/paging
@@ -230,7 +229,7 @@ dependencies {
230
229
231
230
// firebase
232
231
// https://firebase.google.com/docs/android/setup
233
- implementation(platform(" com.google.firebase:firebase-bom:31.2.3 " ))
232
+ implementation(platform(" com.google.firebase:firebase-bom:31.5.0 " ))
234
233
implementation(" com.google.firebase:firebase-analytics-ktx" )
235
234
implementation(" com.google.firebase:firebase-crashlytics-ktx" )
236
235
implementation(" com.google.firebase:firebase-messaging-ktx" )
@@ -248,12 +247,12 @@ dependencies {
248
247
249
248
// unit test
250
249
testImplementation(" junit:junit:4.13.2" )
251
- testImplementation(" org.mockito:mockito-core:5.2 .0" )
250
+ testImplementation(" org.mockito:mockito-core:5.3 .0" )
252
251
// testImplementation("org.mockito:mockito-inline:3.3.3")
253
- testImplementation(" io.mockk:mockk:1.13.4 " )
252
+ testImplementation(" io.mockk:mockk:1.13.5 " )
254
253
testImplementation(" androidx.arch.core:core-testing:2.2.0" )
255
254
testImplementation(" com.squareup.okhttp3:mockwebserver:5.0.0-alpha.2" )
256
- testImplementation(" org.jetbrains.kotlin:kotlin-stdlib:1.8.10 " )
255
+ testImplementation(" org.jetbrains.kotlin:kotlin-stdlib:1.8.20 " )
257
256
// testImplementation("org.robolectric:robolectric:4.3")
258
257
259
258
/* *
@@ -373,45 +372,46 @@ dependencies {
373
372
// compose
374
373
// https://developer.android.com/jetpack/compose/interop/adding
375
374
// https://developer.android.com/jetpack/compose/setup
376
- implementation(" androidx.compose:compose-bom:2023.01.00" )
377
- androidTestImplementation(" androidx.compose:compose-bom:2023.01.00" )
378
- // Android Studio Preview support
379
- implementation(" androidx.compose.ui:ui-tooling-preview" )
380
- debugImplementation(" androidx.compose.ui:ui-tooling" )
381
- // Animations
382
- implementation(" androidx.compose.animation:animation" )
375
+ // implementation("androidx.compose.compiler:compiler:1.4.5")
376
+ // implementation("androidx.compose:compose-bom:2023.04.00")
377
+ // androidTestImplementation("androidx.compose:compose-bom:2023.04.00")
383
378
// Foundation (Border, Background, Box, Image, Scroll, shapes, animations, etc.)
384
- implementation(" androidx.compose.foundation:foundation" )
379
+ implementation(" androidx.compose.foundation:foundation:1.4.1 " )
385
380
// or Material Design 2
386
- implementation(" androidx.compose.material:material" )
387
- // Material Design
388
- implementation(" androidx.compose.material3:material3" )
381
+ implementation(" androidx.compose.material:material:1.4.1" )
382
+ // Material Design 3
383
+ implementation(" androidx.compose.material3:material3:1.1.0-beta02" )
384
+ // Android Studio Preview support
385
+ implementation(" androidx.compose.ui:ui-tooling-preview:1.4.1" )
386
+ debugImplementation(" androidx.compose.ui:ui-tooling:1.4.1" )
387
+ // UI Tests
388
+ androidTestImplementation(" androidx.compose.ui:ui-test-junit4:1.5.0-alpha02" )
389
+ debugImplementation(" androidx.compose.ui:ui-test-manifest:1.4.1" )
390
+ // Animations
391
+ implementation(" androidx.compose.animation:animation:1.4.1" )
389
392
// Constraint layout
390
393
implementation(" androidx.constraintlayout:constraintlayout-compose:1.0.1" )
391
394
// Optional - Included automatically by material, only add when you need
392
395
// the icons but not the material library (e.g. when using Material3 or a
393
396
// custom design system based on Foundation)
394
397
// implementation("androidx.compose.material:material-icons-core")
395
398
// Optional - Add full set of material icons
396
- implementation(" androidx.compose.material:material-icons-extended" )
399
+ implementation(" androidx.compose.material:material-icons-extended:1.4.1 " )
397
400
// Optional - Add window size utils
398
- implementation(" androidx.compose.material3:material3-window-size-class" )
401
+ implementation(" androidx.compose.material3:material3-window-size-class:1.0.1 " )
399
402
// Optional - Integration with activities
400
- implementation(" androidx.activity:activity-compose:1.6.1 " )
403
+ implementation(" androidx.activity:activity-compose:1.7.0 " )
401
404
// Optional - Integration with ViewModels
402
- implementation(" androidx.lifecycle:lifecycle-viewmodel-compose:2.6.0 " )
405
+ implementation(" androidx.lifecycle:lifecycle-viewmodel-compose:2.6.1 " )
403
406
// Optional - Integration with LiveData
404
- implementation(" androidx.compose.runtime:runtime-livedata" )
405
- // UI Tests
406
- androidTestImplementation(" androidx.compose.ui:ui-test-junit4" )
407
- debugImplementation(" androidx.compose.ui:ui-test-manifest" )
407
+ implementation(" androidx.compose.runtime:runtime-livedata:1.4.1" )
408
408
// navigation
409
409
implementation(" androidx.navigation:navigation-compose:2.5.3" )
410
410
implementation(" androidx.hilt:hilt-navigation-compose:1.0.0" )
411
411
// https://github.com/skydoves/landscapist
412
- implementation(" com.github.skydoves:landscapist -bom:2.1.7" )
413
- implementation(" com.github.skydoves:landscapist-glide" )
414
- implementation(" com.github.skydoves:landscapist-placeholder" )
412
+ // implementation("com.github.skydoves:landscape -bom:2.1.7")
413
+ implementation(" com.github.skydoves:landscapist-glide:2.1.11 " )
414
+ implementation(" com.github.skydoves:landscapist-placeholder:2.1.11 " )
415
415
// https://google.github.io/accompanist/
416
416
// https://github.com/google/accompanist
417
417
val accompanistVersion = " 0.28.0"
@@ -461,15 +461,27 @@ project.afterEvaluate {
461
461
sourceName = buildTypeName
462
462
} else {
463
463
sourcePath = " ${productFlavorName} /${buildTypeName} "
464
- sourceName = " ${productFlavorName}${buildTypeName.capitalize()} "
464
+ sourceName = " ${productFlavorName}${buildTypeName.replaceFirstChar {
465
+ if (it.isLowerCase()) it.titlecase(
466
+ Locale .getDefault()
467
+ ) else it.toString()
468
+ }} "
465
469
}
466
- val testTaskName = " test${sourceName.capitalize()} UnitTest"
470
+ val testTaskName = " test${sourceName.replaceFirstChar {
471
+ if (it.isLowerCase()) it.titlecase(
472
+ Locale .getDefault()
473
+ ) else it.toString()
474
+ }} UnitTest"
467
475
// Create coverage task of form 'testFlavorTypeCoverage' depending on 'testFlavorTypeUnitTest'
468
476
task<JacocoReport >(" ${testTaskName} Coverage" ) {
469
477
// where store all test to run follow second way above
470
478
group = " coverage"
471
479
description =
472
- " Generate Jacoco coverage reports on the ${sourceName.capitalize()} build."
480
+ " Generate Jacoco coverage reports on the ${sourceName.replaceFirstChar {
481
+ if (it.isLowerCase()) it.titlecase(
482
+ Locale .getDefault()
483
+ ) else it.toString()
484
+ }} build."
473
485
val excludeFiles = arrayListOf (
474
486
" **/R.class" , " **/R$*.class" , " **/BuildConfig.*" , " **/Manifest*.*" ,
475
487
" **/*Test*.*" , " android/**/*.*" ,
0 commit comments