add plugin common detekt
This commit is contained in:
@@ -15,6 +15,12 @@ Set core Java and Kotlin settings and overweight project version with git versio
|
|||||||
* `buildInfo` display name and version, add to `build` task.
|
* `buildInfo` display name and version, add to `build` task.
|
||||||
* `projectInfo` display project, Gradle, and Java information
|
* `projectInfo` display project, Gradle, and Java information
|
||||||
|
|
||||||
|
### Plugin Common Detekt
|
||||||
|
|
||||||
|
id `ltd.hlaeja.plugin.hlaeja-common-plugin.common-detekt`
|
||||||
|
|
||||||
|
Detect is a code smell analysis for your Kotlin projects.
|
||||||
|
|
||||||
## Releasing plugin
|
## Releasing plugin
|
||||||
|
|
||||||
Run `release.sh` script from `master` branch.
|
Run `release.sh` script from `master` branch.
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ plugins {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
implementation(hlaeja.io.gitlab.arturbosch.detekt.gradle.plugin)
|
||||||
implementation(hlaeja.ltd.hlaeja.plugin.core)
|
implementation(hlaeja.ltd.hlaeja.plugin.core)
|
||||||
implementation(hlaeja.org.jetbrains.kotlin.gradle.plugin)
|
implementation(hlaeja.org.jetbrains.kotlin.gradle.plugin)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
import io.gitlab.arturbosch.detekt.Detekt
|
||||||
|
import io.gitlab.arturbosch.detekt.extensions.DetektExtension.Companion.DEFAULT_SRC_DIR_KOTLIN
|
||||||
|
import io.gitlab.arturbosch.detekt.extensions.DetektExtension.Companion.DEFAULT_TEST_SRC_DIR_KOTLIN
|
||||||
|
|
||||||
|
plugins {
|
||||||
|
id("io.gitlab.arturbosch.detekt")
|
||||||
|
}
|
||||||
|
|
||||||
|
detekt {
|
||||||
|
buildUponDefaultConfig = true
|
||||||
|
basePath = projectDir.path
|
||||||
|
source.from(
|
||||||
|
DEFAULT_SRC_DIR_KOTLIN,
|
||||||
|
DEFAULT_TEST_SRC_DIR_KOTLIN,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
tasks.withType<Detekt> {
|
||||||
|
reports {
|
||||||
|
html.required = false
|
||||||
|
md.required = false
|
||||||
|
sarif.required = true
|
||||||
|
txt.required = false
|
||||||
|
xml.required = false
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
plugins {
|
plugins {
|
||||||
|
id("ltd.hlaeja.plugin.hlaeja-common-plugin.common-detekt")
|
||||||
id("ltd.hlaeja.plugin.hlaeja-core-plugin")
|
id("ltd.hlaeja.plugin.hlaeja-core-plugin")
|
||||||
|
|
||||||
kotlin("jvm")
|
kotlin("jvm")
|
||||||
|
|||||||
Reference in New Issue
Block a user