From e33d623d406be89039d55c07765e5158c73d7a60 Mon Sep 17 00:00:00 2001 From: topjohnwu Date: Sat, 15 Aug 2020 05:43:28 -0700 Subject: [PATCH] Update dependencies --- app/build.gradle.kts | 12 ++++++------ build.gradle.kts | 7 +++++-- buildSrc/src/main/java/BuildSource.kt | 9 +++------ 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 8edd4a019..54e75a516 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -76,6 +76,7 @@ tasks["preBuild"]?.dependsOn(copyUtils) dependencies { implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.jar")))) + implementation(kotlin("stdlib")) implementation(project(":app:shared")) implementation(project(":app:signing")) @@ -83,20 +84,18 @@ dependencies { implementation("com.github.topjohnwu:indeterminate-checkbox:1.0.7") implementation("com.jakewharton.timber:timber:4.7.1") - implementation(kotlin("stdlib")) - val vBAdapt = "4.0.0" val bindingAdapter = "me.tatarka.bindingcollectionadapter2:bindingcollectionadapter" implementation("${bindingAdapter}:${vBAdapt}") implementation("${bindingAdapter}-recyclerview:${vBAdapt}") - val vMarkwon = "4.4.0" + val vMarkwon = "4.5.1" implementation("io.noties.markwon:core:${vMarkwon}") implementation("io.noties.markwon:html:${vMarkwon}") implementation("io.noties.markwon:image:${vMarkwon}") implementation("com.caverock:androidsvg:1.4") - val vLibsu = "3.0.1" + val vLibsu = "3.0.2" implementation("com.github.topjohnwu.libsu:core:${vLibsu}") implementation("com.github.topjohnwu.libsu:io:${vLibsu}") @@ -128,8 +127,9 @@ dependencies { implementation("androidx.room:room-ktx:${vRoom}") kapt("androidx.room:room-compiler:${vRoom}") - implementation("androidx.navigation:navigation-fragment-ktx:${Deps.vNav}") - implementation("androidx.navigation:navigation-ui-ktx:${Deps.vNav}") + val vNav: String by rootProject.extra + implementation("androidx.navigation:navigation-fragment-ktx:${vNav}") + implementation("androidx.navigation:navigation-ui-ktx:${vNav}") implementation("androidx.biometric:biometric:1.0.1") implementation("androidx.constraintlayout:constraintlayout:2.0.0-rc1") diff --git a/build.gradle.kts b/build.gradle.kts index 8fe9b99c7..508a81705 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -14,10 +14,13 @@ buildscript { maven { url = uri("https://kotlin.bintray.com/kotlinx") } } + val vNav = "2.3.0" + extra["vNav"] = vNav + dependencies { classpath("com.android.tools.build:gradle:4.0.1") classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.72") - classpath("androidx.navigation:navigation-safe-args-gradle-plugin:${Deps.vNav}") + classpath("androidx.navigation:navigation-safe-args-gradle-plugin:${vNav}") // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files @@ -59,7 +62,7 @@ subprojects { plugins.hasPlugin("com.android.application")) { android.apply { compileSdkVersion(30) - buildToolsVersion = "30.0.1" + buildToolsVersion = "30.0.2" defaultConfig { if (minSdkVersion == null) diff --git a/buildSrc/src/main/java/BuildSource.kt b/buildSrc/src/main/java/BuildSource.kt index fd197caf8..58c8d84e4 100644 --- a/buildSrc/src/main/java/BuildSource.kt +++ b/buildSrc/src/main/java/BuildSource.kt @@ -2,13 +2,10 @@ import org.gradle.api.GradleException import org.gradle.api.Plugin import org.gradle.api.Project +import org.gradle.kotlin.dsl.provideDelegate import java.io.File import java.util.* -object Deps { - const val vNav = "2.3.0" -} - private val props = Properties() object Config { @@ -18,8 +15,8 @@ object Config { class MagiskPlugin : Plugin { override fun apply(project: Project) { - val file = project.findProperty("configPath")?.let { File(it as String) } - ?: project.file("config.prop") + val configPath: String? by project + val file = configPath?.let { File(it) } ?: project.file("config.prop") if (!file.exists()) throw GradleException("Please setup config.prop")