mirror of
https://github.com/null2264/yokai.git
synced 2025-07-18 06:46:57 +00:00
refactor: Modularize the project
This commit is contained in:
parent
7e7a37bc53
commit
2df2780912
85 changed files with 1358 additions and 248 deletions
|
@ -1,3 +1,7 @@
|
|||
import com.android.build.gradle.BaseExtension
|
||||
import com.android.build.gradle.BasePlugin
|
||||
import org.gradle.api.tasks.testing.logging.TestLogEvent
|
||||
import org.jetbrains.kotlin.gradle.tasks.KotlinJvmCompile
|
||||
import java.util.*
|
||||
|
||||
plugins {
|
||||
|
@ -23,6 +27,45 @@ buildscript {
|
|||
}
|
||||
}
|
||||
|
||||
subprojects {
|
||||
tasks.withType<KotlinJvmCompile> {
|
||||
kotlinOptions {
|
||||
jvmTarget = JavaVersion.VERSION_17.toString()
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType<Test> {
|
||||
useJUnitPlatform()
|
||||
testLogging {
|
||||
events(TestLogEvent.PASSED, TestLogEvent.SKIPPED, TestLogEvent.FAILED)
|
||||
}
|
||||
}
|
||||
|
||||
plugins.withType<BasePlugin> {
|
||||
configure<BaseExtension> {
|
||||
compileSdkVersion(AndroidConfig.compileSdk)
|
||||
|
||||
defaultConfig {
|
||||
minSdk = AndroidConfig.minSdk
|
||||
targetSdk = AndroidConfig.targetSdk
|
||||
ndk {
|
||||
version = AndroidConfig.ndk
|
||||
}
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = JavaVersion.VERSION_17
|
||||
targetCompatibility = JavaVersion.VERSION_17
|
||||
isCoreLibraryDesugaringEnabled = true
|
||||
}
|
||||
|
||||
dependencies {
|
||||
add("coreLibraryDesugaring", libs.desugar)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks.named("dependencyUpdates", com.github.benmanes.gradle.versions.updates.DependencyUpdatesTask::class.java).configure {
|
||||
rejectVersionIf {
|
||||
val stableKeyword = listOf("RELEASE", "FINAL", "GA").any { candidate.version.uppercase(Locale.ROOT).contains(it) }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue