-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
121 lines (104 loc) · 3.22 KB
/
build.gradle
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
buildscript {
repositories {
mavenCentral()
}
}
plugins {
id "java-library"
id "io.spring.dependency-management" version "1.1.0"
id "com.github.johnrengelman.shadow" version "7.1.2"
id "io.fairyproject" version "0.7.4b1-SNAPSHOT"
}
group = "dev.craftplugins"
version = "1.2.0"
repositories {
mavenLocal()
mavenCentral()
maven {
name "Jitpack"
url "https://jitpack.io"
}
maven {
name "Imanity"
url "https://repo.imanity.dev/imanity-libraries"
}
maven {
name "PaperMC"
url "https://repo.papermc.io/repository/maven-public"
}
maven {
url "https://repo.codemc.io/repository/maven-releases/"
}
}
dependencies {
compileOnly("org.spigotmc:spigot-api:1.19.4-R0.1-SNAPSHOT")
// Jabel
annotationProcessor("com.github.bsideup.jabel:jabel-javac-plugin:0.4.2")
compileOnly("com.github.bsideup.jabel:jabel-javac-plugin:0.4.2")
}
dependencies {
api("io.fairyproject:bukkit-bundles")
api("io.fairyproject:mc-animation")
api("io.fairyproject:bukkit-command")
api("io.fairyproject:bukkit-menu")
api("io.fairyproject:mc-hologram")
api("io.fairyproject:core-config")
api("io.fairyproject:bukkit-xseries")
api("io.fairyproject:bukkit-items")
api("io.fairyproject:mc-nametag")
api("io.fairyproject:mc-sidebar")
api("io.fairyproject:bukkit-visibility")
api("io.fairyproject:bukkit-visual")
api("io.fairyproject:bukkit-timer")
api("io.fairyproject:bukkit-nbt")
api("io.fairyproject:mc-map")
api("io.fairyproject:mc-tablist")
api(libs.bundles.configurate)
}
fairy {
name.set("CraftCore")
mainPackage.set(findProperty("plugin.package").toString())
fairyPackage.set(findProperty("plugin.package").toString())
bukkitProperties().bukkitApi = "1.13"
}
configure([tasks.compileJava]) {
sourceCompatibility = 17 // for the IDE support
options.release = 8
options.encoding = "UTF-8"
javaCompiler = javaToolchains.compilerFor {
languageVersion = JavaLanguageVersion.of(17)
}
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
}
shadowJar {
relocate("io.fairyproject", "" + findProperty("plugin.package") + ".fairy")
relocate("net.kyori", "" + findProperty("plugin.package") + ".fairy.libs.kyori")
relocate("com.github.retrooper.packetevents", "" + findProperty("plugin.package") + ".fairy.libs.packetevents")
relocate("org.yaml.snakeyaml", "" + findProperty("plugin.package") + ".snakeyaml")
relocate("com.cryptomorin.xseries", "" + findProperty("plugin.package") + ".xseries")
relocate("org.spongepowered.configurate", "" + findProperty("plugin.package") + ".libs.configurate")
relocate("io.leangen.geantyref", "" + findProperty("plugin.package") + ".libs.geantyref")
relocate("org.spongepowered.configurate", "" + findProperty("plugin.package") + ".libs.configurate")
archiveFileName.set("CraftCore.jar")
}
build {
dependsOn(shadowJar)
}
test {
useJUnitPlatform()
}
runServer {
version = "1.19.4"
}
processResources {
def props = [version: version]
inputs.properties props
filteringCharset "UTF-8"
filesMatching("plugin.yml") {
expand props
}
}