-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
65 lines (50 loc) · 1.39 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
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
kotlin("jvm") version "1.8.0"
id("com.github.johnrengelman.shadow") version "7.1.2"
}
group = "tech.cerberusLabs"
version = "1.0-SNAPSHOT"
repositories {
mavenCentral()
maven("https://repo.papermc.io/repository/maven-public/")
maven("https://jitpack.io")
}
val shadowDependencies = listOf(
"com.github.Cerberus-Labs-Technologies:License-Manager-Kotlin:v1.0.9"
)
dependencies {
// Minecraft PaperMC Dependencies
compileOnly("io.papermc.paper:paper-api:1.19.3-R0.1-SNAPSHOT")
compileOnly("com.mojang:authlib:1.6.25")
shadowDependencies.forEach { dependency ->
implementation(dependency)
shadow(dependency)
}
}
tasks.test {
useJUnitPlatform()
}
tasks {
build {
dependsOn("shadowJar")
}
withType<KotlinCompile> {
kotlinOptions.jvmTarget = "17"
kotlinOptions.freeCompilerArgs += "-opt-in=kotlin.RequiresOptIn"
}
withType<ProcessResources> {
filesMatching("plugin.yml") {
expand(project.properties)
}
}
withType<ShadowJar> {
mergeServiceFiles()
configurations = listOf(project.configurations.shadow.get())
archiveFileName.set("Plugin.jar")
}
}
java {
toolchain.languageVersion.set(JavaLanguageVersion.of(17))
}