Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump dependencies #58

Merged
merged 3 commits into from
Jan 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 12 additions & 13 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("UnstableApiUsage")

import java.io.FileInputStream
import java.util.Properties
import com.android.build.api.variant.FilterConfiguration.FilterType.*
Expand Down Expand Up @@ -119,11 +117,12 @@ android {

buildFeatures {
compose = true
buildConfig = true
}

composeOptions {
// https://developer.android.com/jetpack/androidx/releases/compose-kotlin
kotlinCompilerExtensionVersion = "1.4.7"
kotlinCompilerExtensionVersion = "1.5.7"
}

packaging {
Expand Down Expand Up @@ -158,13 +157,13 @@ dependencies {
implementation(libs.androidx.core.ktx)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.lifecycle.runtime.compose)
implementation("androidx.activity:activity-compose:1.7.2")
implementation("androidx.work:work-runtime-ktx:2.8.1")
implementation(libs.androidx.activity.compose)
implementation(libs.androidx.work.runtime.ktx)

implementation(libs.compose.ui)
implementation(libs.compose.ui.tooling.preview)

implementation("androidx.navigation:navigation-compose:2.6.0")
implementation(libs.androidx.navigation.compose)
implementation(libs.compose.material)
implementation(libs.compose.material.icons.core)
implementation(libs.compose.material.icons.extended)
Expand All @@ -173,20 +172,20 @@ dependencies {
implementation(libs.accompanist.webview)
implementation(libs.accompanist.systemuicontroller)

implementation("com.google.android.material:material:1.9.0")
implementation(libs.android.material)

implementation("androidx.webkit:webkit:1.7.0")
implementation(libs.androidx.webkit)

implementation(libs.hilt.android)
kapt(libs.hilt.compiler)
kapt("androidx.hilt:hilt-compiler:1.0.0")
kapt(libs.androidx.hilt.compiler)
// https://github.com/google/dagger/issues/2601#issuecomment-1174506373
implementation("androidx.hilt:hilt-navigation-compose:1.0.0")
implementation("androidx.hilt:hilt-work:1.0.0")
implementation(libs.androidx.hilt.navigation.compose)
implementation(libs.androidx.hilt.work)

implementation("androidx.datastore:datastore-preferences:1.0.0")
implementation(libs.androidx.datastore.preferences)

implementation("androidx.core:core-splashscreen:1.0.1")
implementation(libs.androidx.core.splashscreen)

testImplementation(libs.junit)
androidTestImplementation(libs.androidx.test.ext.junit)
Expand Down
12 changes: 6 additions & 6 deletions app/src/main/java/org/dianqk/ruslin/RuslinApplication.kt
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ class RuslinApplication : Application(), Configuration.Provider {
@ApplicationScope
lateinit var applicationScope: CoroutineScope

override val workManagerConfiguration: Configuration
get() = Configuration.Builder()
.setWorkerFactory(workerFactory)
.setMinimumLoggingLevel(Log.DEBUG)
.build()

override fun onCreate() {
super.onCreate()
notesRepository.doSync(isOnStart = true, fromScratch = false)
}

override fun getWorkManagerConfiguration() =
Configuration.Builder()
.setWorkerFactory(workerFactory)
.setMinimumLoggingLevel(Log.DEBUG)
.build()
}
4 changes: 2 additions & 2 deletions app/src/main/java/org/dianqk/ruslin/ui/RuslinApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.tooling.preview.Preview
import com.google.accompanist.navigation.animation.rememberAnimatedNavController
import androidx.navigation.compose.rememberNavController
import org.dianqk.ruslin.ui.theme.RuslinTheme

@OptIn(ExperimentalMaterial3Api::class, ExperimentalAnimationApi::class)
@Composable
fun RuslinApp() {
RuslinTheme {
val navController = rememberAnimatedNavController()
val navController = rememberNavController()
val navigationActions = remember(navController) {
RuslinNavigationActions(navController)
}
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/org/dianqk/ruslin/ui/RuslinNavGraph.kt
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import androidx.compose.runtime.remember
import androidx.compose.ui.Modifier
import androidx.navigation.NavHostController
import androidx.navigation.NavType
import androidx.navigation.compose.rememberNavController
import androidx.navigation.navArgument
import com.google.accompanist.navigation.animation.AnimatedNavHost
import com.google.accompanist.navigation.animation.rememberAnimatedNavController
import org.dianqk.ruslin.ui.RuslinDestinationsArgs.FOLDER_ID_ARG
import org.dianqk.ruslin.ui.RuslinDestinationsArgs.IS_PREVIEW_ARG
import org.dianqk.ruslin.ui.RuslinDestinationsArgs.NOTE_ID_ARG
Expand All @@ -28,7 +28,7 @@ import org.dianqk.ruslin.ui.page.settings.tools.log.LogPage
@OptIn(ExperimentalAnimationApi::class)
@Composable
fun RuslinNavGraph(
navController: NavHostController = rememberAnimatedNavController(),
navController: NavHostController = rememberNavController(),
navigationActions: RuslinNavigationActions = remember(navController) {
RuslinNavigationActions(navController)
},
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@ plugins {
}

tasks.register("clean", Delete::class) {
delete(rootProject.buildDir)
delete(rootProject.layout.buildDirectory)
}
1 change: 0 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ kotlin.code.style=official
# resources declared in the library itself and none from the library's dependencies,
# thereby reducing the size of the R class for that library
android.nonTransitiveRClass=true
android.defaults.buildfeatures.buildconfig=true
# Enable non-final resource IDs for faster incremental compilation.
android.nonFinalResIds=true
android.enableR8.fullMode=true
46 changes: 32 additions & 14 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,37 +1,54 @@
[versions]
# plugin
androidGradlePlugin = "8.1.2"
hilt = "2.46.1"
kotlin = "1.8.21"
androidxBenchmark = "1.1.1"
androidxCore = "1.10.1"
activityCompose = "1.8.2"
androidGradlePlugin = "8.2.1"
coreSplashscreen = "1.0.1"
datastorePreferences = "1.0.0"
hiltDragger = "2.50"
hiltAndroid = "1.1.0"
kotlin = "1.9.21"
androidxBenchmark = "1.2.2"
androidxCore = "1.12.0"

# sdk
compileSdkVersion = "34"
kotlinxCoroutinesCore = "1.7.3"
minSdkVersion = "28"
navigationCompose = "2.7.6"
targetSdkVersion = "34"
buildToolsVersion = "34.0.0"
ndkVersion = "26.1.10909125"

# library
appcompat = "1.6.1"
material = "1.9.0"
compose = "1.4.3"
accompanist = "0.30.1"
material3 = "1.1.1"
lifecycleRuntime = "2.6.1"
material = "1.11.0"
compose = "1.5.4"
accompanist = "0.32.0"
material3 = "1.1.2"
lifecycleRuntime = "2.6.2"

# test
junit = "4.13.2"
testExtJunit = "1.1.5"
testeSpresso = "3.5.1"
benchmarkJunit4 = "1.1.1"
benchmarkJunit4 = "1.2.2"
testRunner = "1.5.2"
webkit = "1.9.0"
workRuntimeKtx = "2.9.0"

[libraries]
androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "activityCompose" }
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "androidxCore" }
androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
android-material = { group = "com.google.android.material", name = "material", version.ref = "material" }
androidx-core-splashscreen = { module = "androidx.core:core-splashscreen", version.ref = "coreSplashscreen" }
androidx-datastore-preferences = { module = "androidx.datastore:datastore-preferences", version.ref = "datastorePreferences" }
androidx-hilt-compiler = { module = "androidx.hilt:hilt-compiler", version.ref = "hiltAndroid" }
androidx-hilt-navigation-compose = { module = "androidx.hilt:hilt-navigation-compose", version.ref = "hiltAndroid" }
androidx-hilt-work = { module = "androidx.hilt:hilt-work", version.ref = "hiltAndroid" }
androidx-navigation-compose = { module = "androidx.navigation:navigation-compose", version.ref = "navigationCompose" }
androidx-webkit = { module = "androidx.webkit:webkit", version.ref = "webkit" }
androidx-work-runtime-ktx = { module = "androidx.work:work-runtime-ktx", version.ref = "workRuntimeKtx" }
compose-material = { group = "androidx.compose.material", name = "material", version.ref = "compose" }
compose-material-icons-core = { group = "androidx.compose.material", name = "material-icons-core", version.ref = "compose" }
compose-material-icons-extended = { group = "androidx.compose.material", name = "material-icons-extended", version.ref = "compose" }
Expand All @@ -51,14 +68,15 @@ accompanist-systemuicontroller = { group = "com.google.accompanist", name = "acc
compose-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4", version.ref = "compose" }
compose-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling", version.ref = "compose" }
compose-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest", version.ref = "compose" }
hilt-android = { group = "com.google.dagger", name = "hilt-android", version.ref = "hilt" }
hilt-compiler = { group = "com.google.dagger", name = "hilt-compiler", version.ref = "hilt" }
hilt-android = { group = "com.google.dagger", name = "hilt-android", version.ref = "hiltDragger" }
hilt-compiler = { group = "com.google.dagger", name = "hilt-compiler", version.ref = "hiltDragger" }
kotlinx-coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "kotlinxCoroutinesCore" }

[plugins]
android-application = { id = "com.android.application", version.ref = "androidGradlePlugin" }
android-library = { id = "com.android.library", version.ref = "androidGradlePlugin" }
android-test = { id = "com.android.test", version.ref = "androidGradlePlugin" }
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hiltDragger" }
kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
kotlin-gradlePlugin = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
2 changes: 0 additions & 2 deletions mdrender/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("UnstableApiUsage")

plugins {
id("com.android.library")
id("org.jetbrains.kotlin.android")
Expand Down
2 changes: 0 additions & 2 deletions mdrenderbenchmark/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("UnstableApiUsage")

plugins {
id("com.android.library")
id("androidx.benchmark")
Expand Down
Loading