This repository was archived by the owner on Apr 10, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
110 lines (96 loc) · 3.28 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
110 lines (96 loc) · 3.28 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
101
102
103
104
105
106
107
108
109
110
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
plugins {
kotlin("jvm") version "2.1.10"
id("com.gradleup.shadow") version "8.3.5"
id("net.minecrell.plugin-yml.bukkit") version "0.6.0"
id("xyz.jpenilla.run-paper") version "3.0.2"
}
repositories {
mavenLocal()
mavenCentral()
maven("https://central.sonatype.com/repository/maven-snapshots/")
maven("https://repo.papermc.io/repository/maven-public/")
maven("https://repo.alessiodp.com/releases/")
maven("https://jitpack.io")
}
dependencies {
fun compileOnlyAndTestImpl(dependencyNotation: Any) {
compileOnly(dependencyNotation)
testImplementation(dependencyNotation)
}
compileOnly(kotlin("stdlib")) // loaded through library loader
compileOnly(kotlin("reflect")) // loaded through library loader
compileOnlyAndTestImpl("io.papermc.paper:paper-api:1.21.11-R0.1-SNAPSHOT")
compileOnlyAndTestImpl("com.github.slimefun:Slimefun4:experimental-SNAPSHOT")
compileOnly("net.guizhanss:SlimefunTranslation:e6da231617")
compileOnly("com.github.schntgaispock:SlimeHUD:1.3.0")
compileOnly("com.github.SlimefunGuguProject:InfinityExpansion:bebf0bd0f9")
compileOnly("com.github.VoperAD:SlimeFrame:8af2379a01")
compileOnly("net.guizhanss:InfinityExpansion2:8d3e6c40f6")
implementation("org.bstats:bstats-bukkit:3.1.0")
implementation("net.guizhanss:guizhanlib-all:2.5.0")
implementation("net.guizhanss:guizhanlib-kt-all:0.2.0")
testImplementation(kotlin("test"))
testImplementation("org.mockbukkit.mockbukkit:mockbukkit-v1.21:4.10.0")
}
group = "net.guizhanss"
description = "FastMachines"
val mainPackage = "net.guizhanss.fastmachines"
java {
disableAutoTargetJvm()
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
kotlin {
compilerOptions {
javaParameters = true
jvmTarget = JvmTarget.JVM_17
}
}
tasks.shadowJar {
fun doRelocate(from: String, to: String? = null) {
val last = to ?: from.split(".").last()
relocate(from, "$mainPackage.libs.$last")
}
doRelocate("net.byteflux.libby")
doRelocate("net.guizhanss.guizhanlib")
doRelocate("org.bstats")
doRelocate("io.papermc.lib", "paperlib")
minimize()
archiveClassifier = ""
}
bukkit {
main = "$mainPackage.FastMachines"
apiVersion = "1.18"
authors = listOf("ybw0014")
description = "More Slimefun machines that bulk craft items with all shapeless recipes"
depend = listOf("Slimefun")
softDepend = listOf(
"GuizhanLibPlugin",
"SlimefunTranslation",
"InfinityExpansion",
"SlimeFrame",
"SlimeHUD",
"InfinityExpansion2",
)
loadBefore = listOf(
"SlimeCustomizer",
"RykenSlimeCustomizer",
"SlimeFunRecipe"
)
}
tasks.runServer {
downloadPlugins {
// Slimefun
url("https://builds.guizhanss.com/api/download/SlimefunGuguProject/Slimefun4/master/latest")
// SlimeHUD
url("https://blob.build/dl/SlimeHUD/Dev/latest")
// GuizhanCraft for testing convenient
url("https://builds.guizhanss.com/api/download/ybw0014/GuizhanCraft/master/latest")
}
jvmArgs("-Dcom.mojang.eula.agree=true")
minecraftVersion("1.21.11")
}
tasks.test {
useJUnitPlatform()
}