-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
73 lines (65 loc) · 1.74 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
buildscript {
val kotlin_version by extra("1.4.21")
repositories {
google()
jcenter()
}
dependencies {
classpath("com.android.tools.build:gradle:4.1.1")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
classpath("androidx.navigation:navigation-safe-args-gradle-plugin:2.3.2")
classpath("com.google.dagger:hilt-android-gradle-plugin:2.30.1-alpha")
classpath ("de.mannodermaus.gradle.plugins:android-junit5:1.7.0.0")
}
}
plugins {
id("org.jlleitschuh.gradle.ktlint") version "9.2.1"
id("io.gitlab.arturbosch.detekt") version "1.10.0"
}
allprojects {
repositories {
google()
jcenter()
}
}
subprojects {
apply(plugin = "org.jlleitschuh.gradle.ktlint")
apply(plugin = "io.gitlab.arturbosch.detekt")
ktlint {
debug.set(false)
}
val detekt by tasks
val ktlintCheck by tasks
tasks.register("codeStyleCheck") {
group = "verification"
description = "Combined codestyle checks"
dependsOn(detekt, ktlintCheck)
}
detekt {
toolVersion = "1.10.0"
input = files(
"src/main/kotlin"
)
parallel = false
config = files("$rootDir/config/detekt/detekt.yml")
buildUponDefaultConfig = false
disableDefaultRuleSets = false
debug = false
ignoreFailures = false
reports {
xml {
enabled = false
}
html {
enabled = false
}
txt {
enabled = true
destination = file("build/reports/detekt.txt")
}
}
}
}
task<Delete>("clean") {
delete(rootProject.buildDir)
}