-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
61 lines (49 loc) · 1.3 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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
`maven-publish` // for jitpack
kotlin("jvm") version "1.5.21"
jacoco
}
jacoco {
toolVersion = "0.8.7"
}
group = "com.github.kokorins"
repositories {
mavenCentral()
}
tasks {
withType<KotlinCompile> {
kotlinOptions.jvmTarget = "11"
}
withType<Test> {
testLogging {
showStandardStreams = true
}
useJUnitPlatform()
}
}
val slf4j = "1.7.32"
val kotest = "4.6.1"
dependencies {
implementation(kotlin("stdlib"))
implementation("org.slf4j:slf4j-api:$slf4j")
implementation("org.slf4j:slf4j-simple:$slf4j")
testImplementation("io.kotest:kotest-runner-junit5:$kotest")
testImplementation("io.kotest:kotest-assertions-core-jvm:$kotest")
}
tasks.test {
finalizedBy(tasks.jacocoTestReport)
}
tasks.jacocoTestReport {
dependsOn(tasks.test)
}
task("fat-jar", Jar::class) {
archiveBaseName.set("md-generator")
manifest {
attributes["Implementation-Title"] = "Markdown Generator"
attributes["Implementation-Version"] = archiveVersion
}
exclude("META-INF/*.RSA", "META-INF/*.SF", "META-INF/*.DSA")
from(configurations.runtimeClasspath.get().map { if (it.isDirectory) it else zipTree(it) })
with(tasks.jar.get() as CopySpec)
}