chore: owlでdetektが動作するように

This commit is contained in:
usbharu 2024-09-17 21:53:54 +09:00
parent 26b3bdd721
commit 1a2142e83b
No known key found for this signature in database
GPG Key ID: 95CBCF7046307B77
3 changed files with 19 additions and 5 deletions

View File

@ -1,5 +1,3 @@
import dev.usbharu.hideout.core.infrastructure.exposedrepository.UserDetails.password
/*
* Copyright (C) 2024 usbharu
*

View File

@ -1,4 +1,3 @@
import dev.usbharu.hideout.core.infrastructure.exposedrepository.Instance.version
import kotlinx.kover.gradle.plugin.dsl.CoverageUnit
plugins {

View File

@ -32,6 +32,7 @@ subprojects {
plugin("org.jetbrains.kotlin.jvm")
plugin("maven-publish")
plugin(rootProject.libs.plugins.kover.get().pluginId)
plugin(rootProject.libs.plugins.detekt.get().pluginId)
}
kotlin {
jvmToolchain(21)
@ -40,9 +41,19 @@ subprojects {
dependencies {
implementation("org.slf4j:slf4j-api:2.0.15")
testImplementation("org.junit.jupiter:junit-jupiter:5.10.3")
detektPlugins(rootProject.libs.detekt.formatting)
}
detekt {
parallel = true
config.setFrom(files("$rootDir/../detekt.yml"))
buildUponDefaultConfig = true
basePath = "${projectDir}/src/main/kotlin"
autoCorrect = true
}
project.gradle.taskGraph.whenReady {
if (this.hasTask(":koverGenerateArtifact")) {
val task = this.allTasks.find { println(it.name);it.name == "test" }
@ -94,7 +105,13 @@ dependencies {
kover(project(":owl-producer:owl-producer-embedded"))
}
detekt {
parallel = true
config.setFrom(files("../detekt.yml"))
buildUponDefaultConfig = true
basePath = "${projectDir}/src/main/kotlin"
autoCorrect = true
}
project.gradle.taskGraph.whenReady {
if (this.hasTask(":koverGenerateArtifact")) {