-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
122 lines (107 loc) · 4.45 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
/*
* MIT License
*
* Copyright (c) 2023 Wacky Gem
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
val kotlinVersion = "1.9.21"
id("org.springframework.boot") version "3.2.0"
id("io.spring.dependency-management") version "1.1.4"
id("com.google.devtools.ksp") version "1.9.21-1.0.15"
id("org.jetbrains.kotlin.jvm") version kotlinVersion
id("org.jetbrains.kotlin.plugin.spring") version kotlinVersion
id("org.jetbrains.kotlin.kapt") version kotlinVersion
jacoco
}
group = "org.example"
version = "0.1.0"
java.sourceCompatibility = JavaVersion.VERSION_21
repositories {
mavenCentral()
maven { url = uri("https://repo.spring.io/milestone") }
maven { url = uri("https://repo.spring.io/snapshot") }
gradlePluginPortal()
}
val postgreSQLVersion = "42.7.0"
val jimmerVersion = "0.8.46"
val mapstructVersion = "1.6.0.Beta1"
val paseto4jVersion = "2023.1"
val openApiDocVersion = "2.2.0"
dependencies {
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-actuator")
implementation("org.springframework.boot:spring-boot-starter-aop")
implementation("org.springframework.boot:spring-boot-starter-validation")
implementation("org.springframework.boot:spring-boot-starter-data-redis")
implementation("org.springframework.boot:spring-boot-starter-mail")
implementation("org.springframework.boot:spring-boot-starter-thymeleaf")
implementation("org.springframework.boot:spring-boot-starter-security")
implementation("org.springdoc:springdoc-openapi-starter-webmvc-ui:$openApiDocVersion")
implementation("org.babyfish.jimmer:jimmer-spring-boot-starter:$jimmerVersion") {
exclude(group = "org.springframework.boot", module = "spring-boot-autoconfigure")
exclude(group = "org.springframework", module = "spring-expression")
exclude(group = "org.springdoc", module = "springdoc-openapi-ui")
exclude(group = "org.yaml", module = "snakeyaml")
}
implementation("org.flywaydb:flyway-core")
implementation("org.mapstruct:mapstruct:$mapstructVersion")
implementation("io.github.nbaars:paseto4j-version3:$paseto4jVersion")
implementation("at.favre.lib:bcrypt:0.10.2")
ksp("org.babyfish.jimmer:jimmer-ksp:$jimmerVersion")
kapt("org.mapstruct:mapstruct-processor:$mapstructVersion")
kapt("org.babyfish.jimmer:jimmer-mapstruct-apt:$jimmerVersion")
runtimeOnly("org.postgresql:postgresql:$postgreSQLVersion")
developmentOnly("org.springframework.boot:spring-boot-devtools")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testImplementation("org.springframework.boot:spring-boot-testcontainers")
testImplementation("org.testcontainers:junit-jupiter")
testImplementation("org.testcontainers:postgresql")
}
kotlin {
sourceSets.all {
languageSettings {
languageVersion = "2.0"
}
}
}
tasks.withType<KotlinCompile> {
kotlinOptions {
freeCompilerArgs += listOf(
"-Xjsr305=strict"
)
jvmTarget = "21"
}
}
tasks.test {
useJUnitPlatform()
finalizedBy(tasks.jacocoTestReport)
}
tasks.jacocoTestReport {
dependsOn(tasks.test)
reports {
xml.required.set(true)
csv.required.set(false)
html.required.set(true)
html.outputLocation.set(layout.buildDirectory.dir("jacocoHtml"))
}
}