3
0
Mirror von https://github.com/Moulberry/AxiomPaperPlugin.git synchronisiert 2024-11-08 17:40:04 +01:00
AxiomPaperPlugin/build.gradle.kts

60 Zeilen
1.9 KiB
Plaintext

2021-07-08 14:30:01 +02:00
plugins {
`java-library`
2023-04-26 18:58:59 +02:00
id("io.papermc.paperweight.userdev") version "1.5.5"
2023-06-11 22:59:22 +02:00
id("xyz.jpenilla.run-paper") version "2.1.0" // Adds runServer and runMojangMappedServer tasks for testing
2021-07-08 14:30:01 +02:00
}
group = "io.papermc.paperweight"
version = "1.0.0-SNAPSHOT"
2021-08-17 23:37:14 +02:00
description = "Test plugin for paperweight-userdev"
2021-07-08 14:30:01 +02:00
2021-11-18 01:55:32 +01:00
java {
2021-12-06 02:01:56 +01:00
// Configure the java toolchain. This allows gradle to auto-provision JDK 17 on systems that only have JDK 8 installed for example.
2021-11-18 01:55:32 +01:00
toolchain.languageVersion.set(JavaLanguageVersion.of(17))
}
2021-07-08 14:30:01 +02:00
dependencies {
2023-06-28 22:18:30 +02:00
paperweight.paperDevBundle("1.20.1-R0.1-SNAPSHOT")
// paperweight.foliaDevBundle("1.20.1-R0.1-SNAPSHOT")
// paperweight.devBundle("com.example.paperfork", "1.20.1-R0.1-SNAPSHOT")
2021-07-08 14:30:01 +02:00
}
tasks {
2021-12-06 02:01:56 +01:00
// Configure reobfJar to run when invoking the build task
2021-12-23 02:04:48 +01:00
assemble {
2021-07-09 04:57:49 +02:00
dependsOn(reobfJar)
}
2021-07-08 14:30:01 +02:00
compileJava {
2021-12-06 02:01:56 +01:00
options.encoding = Charsets.UTF_8.name() // We want UTF-8 for everything
// Set the release flag. This configures what version bytecode the compiler will emit, as well as what JDK APIs are usable.
// See https://openjdk.java.net/jeps/247 for more information.
2021-12-01 10:48:52 +01:00
options.release.set(17)
2021-07-08 14:30:01 +02:00
}
2021-07-09 04:57:49 +02:00
javadoc {
2021-12-06 02:01:56 +01:00
options.encoding = Charsets.UTF_8.name() // We want UTF-8 for everything
2021-07-09 04:57:49 +02:00
}
processResources {
2021-12-06 02:01:56 +01:00
filteringCharset = Charsets.UTF_8.name() // We want UTF-8 for everything
2023-04-20 17:42:59 +02:00
val props = mapOf(
"name" to project.name,
"version" to project.version,
"description" to project.description,
2023-06-11 22:59:22 +02:00
"apiVersion" to "1.20"
2023-04-20 17:42:59 +02:00
)
inputs.properties(props)
2023-04-20 17:42:59 +02:00
filesMatching("plugin.yml") {
expand(props)
}
2021-12-06 02:01:56 +01:00
}
/*
reobfJar {
// This is an example of how you might change the output location for reobfJar. It's recommended not to do this
// for a variety of reasons, however it's asked frequently enough that an example of how to do it is included here.
outputJar.set(layout.buildDirectory.file("libs/PaperweightTestPlugin-${project.version}.jar"))
2021-07-08 14:30:01 +02:00
}
2021-12-06 02:01:56 +01:00
*/
2021-07-08 14:30:01 +02:00
}