-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle.kts
79 lines (71 loc) · 1.91 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
plugins {
kotlin("jvm") version "2.0.21"
kotlin("kapt") version "2.0.21"
alias(libs.plugins.runvelocity)
alias(libs.plugins.idea.ext)
alias(libs.plugins.blossom)
alias(libs.plugins.shadow)
}
repositories {
maven("https://repo.papermc.io/repository/maven-public/")
}
dependencies {
compileOnly(kotlin("stdlib"))
compileOnly(libs.velocity)
kapt(libs.velocity)
compileOnly(libs.miniplaceholders.api)
compileOnly(libs.miniplaceholders.kotlin)
implementation(libs.configurate.kotlin) {
isTransitive = false
}
implementation(libs.bstats)
implementation(libs.jdwebhooks) {
isTransitive = false
}
}
tasks {
build {
dependsOn(shadowJar)
}
clean {
delete("run")
}
runVelocity {
velocityVersion(libs.versions.velocity.get())
downloadPlugins {
url("https://cdn.modrinth.com/data/1iWA0pjH/versions/3PY3lTnr/MCKotlinVelocity-1.5.1-k2.0.21.jar")
url("https://cdn.modrinth.com/data/HQyibRsN/versions/pxgKwgNJ/MiniPlaceholders-Velocity-2.2.4.jar")
}
}
shadowJar {
archiveBaseName.set(rootProject.name)
archiveClassifier.set("")
listOf(
"org.spongepowered.configurate.kotlin",
"org.bstats",
"io.github._4drian3d.jdwebhooks"
).forEach {
relocate(it, "io.github._4drian3d.clientcatcher.libs.$it")
}
}
compileKotlin {
compilerOptions {
apiVersion.set(org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_2_0)
languageVersion.set(org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_2_0)
}
}
}
sourceSets {
main {
blossom {
kotlinSources {
property("version", project.version.toString())
}
}
}
}
kotlin {
jvmToolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
}