2023-06-15 22:21:19 +00:00
|
|
|
plugins {
|
|
|
|
id("java")
|
|
|
|
id("com.github.johnrengelman.shadow") version "8.1.1"
|
2023-07-16 00:07:47 +00:00
|
|
|
id("io.papermc.paperweight.userdev") version "1.5.5" apply false
|
|
|
|
id("xyz.jpenilla.run-paper") version "2.1.0" apply false
|
2023-06-15 22:21:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
group = "dev.plex"
|
2023-06-20 05:09:26 +00:00
|
|
|
version = "2.1"
|
2023-06-15 22:21:19 +00:00
|
|
|
|
2023-07-16 00:07:47 +00:00
|
|
|
java {
|
|
|
|
toolchain.languageVersion.set(JavaLanguageVersion.of(17))
|
|
|
|
}
|
|
|
|
|
2023-06-15 22:21:19 +00:00
|
|
|
subprojects {
|
2023-06-20 05:09:26 +00:00
|
|
|
apply(plugin = "java")
|
2023-06-15 22:21:19 +00:00
|
|
|
apply(plugin = "com.github.johnrengelman.shadow")
|
2023-07-16 00:07:47 +00:00
|
|
|
apply(plugin = "io.papermc.paperweight.userdev")
|
|
|
|
apply(plugin = "xyz.jpenilla.run-paper")
|
2023-06-15 22:21:19 +00:00
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
|
|
|
|
maven {
|
|
|
|
url = uri("https://repo.papermc.io/repository/maven-public/")
|
|
|
|
}
|
|
|
|
|
|
|
|
maven {
|
|
|
|
url = uri("https://maven.playpro.com/")
|
|
|
|
}
|
|
|
|
}
|
2023-06-20 05:09:26 +00:00
|
|
|
|
|
|
|
dependencies {
|
|
|
|
if (project.name != "shared") {
|
|
|
|
implementation(project(":shared"))
|
|
|
|
}
|
|
|
|
|
|
|
|
compileOnly("net.coreprotect:coreprotect:21.3")
|
|
|
|
}
|
2023-06-15 22:21:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
tasks {
|
|
|
|
shadowJar {
|
|
|
|
archiveBaseName.set("ItemizerX")
|
|
|
|
archiveClassifier.set("")
|
|
|
|
archiveVersion.set("")
|
2023-07-16 00:07:47 +00:00
|
|
|
|
|
|
|
// helper function to relocate a package into our package
|
|
|
|
fun reloc(pkg: String) = relocate(pkg, "io.papermc.paperweight.testplugin.dependency.$pkg")
|
|
|
|
|
|
|
|
// relocate cloud and it's transitive dependencies
|
|
|
|
reloc("cloud.commandframework")
|
|
|
|
reloc("io.leangen.geantyref")
|
2023-06-15 22:21:19 +00:00
|
|
|
}
|
2023-07-16 00:07:47 +00:00
|
|
|
|
|
|
|
compileJava {
|
|
|
|
options.encoding = Charsets.UTF_8.name()
|
|
|
|
options.release.set(17)
|
|
|
|
}
|
|
|
|
|
2023-06-15 22:21:19 +00:00
|
|
|
assemble {
|
|
|
|
dependsOn("shadowJar")
|
2023-07-16 00:07:47 +00:00
|
|
|
dependsOn("reobfJar")
|
2023-06-15 22:21:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jar {
|
|
|
|
enabled = false
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
implementation(project(path = ":core", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":shared", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_20_R1", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_19_R3", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_19_R2", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_19_R1", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_18_R2", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_18_R1", configuration = "shadow"))
|
|
|
|
implementation(project(path = ":v1_17_R1", configuration = "shadow"))
|
|
|
|
}
|