This repository was archived by the owner on Dec 10, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
100 lines (82 loc) · 2.69 KB
/
build.gradle.kts
File metadata and controls
100 lines (82 loc) · 2.69 KB
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
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
import dev.slne.surf.surfapi.gradle.util.slnePublic
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmExtension
buildscript {
repositories {
gradlePluginPortal()
maven("https://repo.slne.dev/repository/maven-public/") { name = "maven-public" }
}
dependencies {
classpath("dev.slne.surf:surf-api-gradle-plugin:1.21.10+")
}
}
plugins {
id("org.jetbrains.kotlinx.binary-compatibility-validator") version "0.17.0"
// id("io.freefair.aspectj.post-compile-weaving") version "8.13.1"
java
}
allprojects {
group = "dev.slne.surf.cloud"
version = findProperty("version") as String
repositories {
slnePublic()
}
if (name == "surf-cloud-bom") {
return@allprojects
}
apply(plugin = "java")
// apply(plugin = "io.freefair.aspectj.post-compile-weaving")
dependencies {
// implementation(platform("org.springframework.boot:spring-boot-dependencies:3.4.4"))
// implementation(platform("io.ktor:ktor-bom:3.0.3"))
// implementation(platform("org.jetbrains.kotlin-wrappers:kotlin-wrappers-bom:2025.4.10"))
implementation(platform(project(":surf-cloud-bom")))
compileOnly("org.springframework.boot:spring-boot-configuration-processor:3.5.6")
// "kapt"("org.springframework.boot:spring-boot-configuration-processor:3.4.3")
testImplementation(kotlin("test"))
}
afterEvaluate {
extensions.findByType<KotlinJvmExtension>()?.apply {
compilerOptions {
}
}
}
tasks {
configureShadowJar()
configureJar()
javadoc {
val options = options as StandardJavadocDocletOptions
options.use()
options.tags("implNote:a:Implementation Note:")
}
test {
useJUnitPlatform()
}
}
}
apiValidation {
ignoredProjects.addAll(
listOf(
"surf-cloud-core",
"surf-cloud-core-common",
"surf-cloud-core-client",
"surf-cloud-bukkit",
"surf-cloud-velocity",
"surf-cloud-standalone",
"surf-cloud-standalone-launcher",
"surf-cloud-test-standalone"
)
)
nonPublicMarkers.add("dev.slne.surf.cloud.api.common.util.annotation.InternalApi")
}
private fun TaskContainerScope.configureShadowJar() = withType<ShadowJar> {
mergeServiceFiles {
path = "META-INF"
exclude("META-INF/MANIFEST.MF")
}
isZip64 = true
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}
private fun TaskContainerScope.configureJar() = withType<Jar> {
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}