-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
54 lines (40 loc) · 1.34 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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
import com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocation
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
plugins {
kotlin("jvm") version "1.7.10"
id("com.github.johnrengelman.shadow") version "7.1.2"
id("io.gitlab.arturbosch.detekt") version "1.22.0"
}
group = "jp.hisano"
version = "1.0-SNAPSHOT"
val shadedPackage = "jp.hisano.cozy.jdbc.mysql.shaded"
repositories {
mavenCentral()
}
dependencies {
implementation("com.github.jasync-sql:jasync-mysql:2.1.16")
testImplementation(kotlin("test"))
testImplementation(platform("org.testcontainers:testcontainers-bom:1.17.6"))
testImplementation("org.testcontainers:junit-jupiter")
testImplementation("org.testcontainers:mysql")
testImplementation("mysql:mysql-connector-java:8.0.32")
}
detekt {
buildUponDefaultConfig = true
config = files("detekt.yml")
}
tasks.test {
useJUnitPlatform()
systemProperty("TARGET_VERSION", System.getProperty("TARGET_VERSION"))
}
tasks.withType<KotlinCompile> {
kotlinOptions.jvmTarget = "1.8"
}
tasks.create<ConfigureShadowRelocation>("relocateShadowJar") {
target = tasks["shadowJar"] as ShadowJar
prefix = shadedPackage
}
tasks.named<ShadowJar>("shadowJar").configure {
dependsOn(tasks["relocateShadowJar"])
}