-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
120 lines (99 loc) · 3.82 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
plugins {
id "java"
id "io.freefair.lombok" version "8.11"
id "com.gradleup.shadow" version "9.0.0-beta4"
id "xyz.jpenilla.run-paper" version "2.3.1"
}
version = project.plugin_version
runServer {
minecraftVersion(bukkit_version)
downloadPlugins.url("https://ci.codemc.io/job/RTUServer/job/RSFramework/lastSuccessfulBuild/artifact/builds/plugin/RSFramework-${rsf_version}.jar")
}
repositories {
mavenCentral()
maven { url = "https://jitpack.io" }
maven {
name = "spigotmc-repo"
url = "https://hub.spigotmc.org/nexus/content/repositories/snapshots/"
}
maven {
name = "papermc"
url = "https://repo.papermc.io/repository/maven-public/"
}
maven {
name = "sonatype"
url = "https://oss.sonatype.org/content/groups/public/"
}
maven { url = "https://repo.codemc.io/repository/rtuserver/" } // RSFramework
maven { url = "https://repo.oraxen.com/releases" } // Oraxen
maven { url = "https://nexus.phoenixdevt.fr/repository/maven-public/" } // MMOItems
maven { url = "https://repo.nexomc.com/releases/" } // Nexo
maven { url = "https://repo.extendedclip.com/content/repositories/placeholderapi/" } // PlaceholderAPI
maven { url = "https://repo.dmulloy2.net/repository/public/" } // ProtocolLib
maven { url = "https://nexus.scarsz.me/content/groups/public/" } // DiscordSRV
maven { url = "https://maven.enginehub.org/repo/" } // WorldGuard
maven { url = "https://mvnrepository.com/artifact/org.projectlombok/lombok" } // Lombok
}
dependencies {
// Spigot/Paper API
if (paper_plugin) compileOnly "io.papermc.paper:paper-api:${api_version}-R0.1-SNAPSHOT"
else compileOnly "org.spigotmc:spigot-api:${api_version}-R0.1-SNAPSHOT"
// RSFramework
compileOnly "kr.rtuserver:framework-api:${rsf_version}"
// Kyori Adventure
compileOnly "net.kyori:adventure-platform-bukkit:4.3.2"
compileOnly "net.kyori:adventure-text-minimessage:4.14.0"
// Google/Apache
compileOnly "com.google.code.gson:gson:2.10.1"
compileOnly "com.google.guava:guava:33.0.0-jre"
compileOnly "org.apache.commons:commons-lang3:3.14.0"
// Custom Item Plugins
compileOnly "com.github.LoneDev6:api-itemsadder:3.6.3-beta-14"
compileOnly "io.th0rgal:oraxen:1.186.1"
compileOnly "net.Indyuce:MMOItems-API:6.9.5-SNAPSHOT"
compileOnly "io.lumine:MythicLib-dist:1.5.2-SNAPSHOT"
compileOnly "com.nexomc:nexo:0.7.0"
// ThirdParty Plugins
compileOnly "me.clip:placeholderapi:2.11.6"
compileOnly "com.comphenix.protocol:ProtocolLib:5.1.0"
compileOnly "net.luckperms:api:5.4"
compileOnly "com.github.MilkBowl:VaultAPI:1.7.1"
compileOnly "com.discordsrv:discordsrv:1.28.0"
compileOnly "com.sk89q.worldguard:worldguard-bukkit:7.0.7"
// Lombok
compileOnly "org.projectlombok:lombok:1.18.36"
annotationProcessor "org.projectlombok:lombok:1.18.36"
}
jar {
finalizedBy shadowJar
}
shadowJar {
setArchiveClassifier("")
doLast {
copy {
from archiveFile.get().asFile into file("$projectDir/builds")
}
}
}
java {
def javaVersion = JavaVersion.toVersion(java_version as Integer)
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
if (JavaVersion.current() < javaVersion) {
toolchain.languageVersion = JavaLanguageVersion.of(java_version as Integer)
}
}
tasks.withType(JavaCompile).configureEach {
options.release = java_version as Integer
}
processResources {
def split = api_version.split("\\.");
def plugin_api_version = split[0] + "." + split[1];
def props =
[version: version, name: project.name, main: plugin_main, api_version: plugin_api_version, author: plugin_author]
inputs.properties props
filteringCharset "UTF-8"
filesMatching("plugin.yml") {
expand props
}
}