2021-11-11 22:22:44 +01:00
|
|
|
import io.papermc.paperweight.userdev.attribute.Obfuscation
|
2021-10-17 16:32:36 +02:00
|
|
|
import org.gradle.api.Project
|
|
|
|
import org.gradle.kotlin.dsl.apply
|
|
|
|
import org.gradle.kotlin.dsl.dependencies
|
|
|
|
|
|
|
|
// For specific version pinning, see
|
|
|
|
// https://papermc.io/repo/service/rest/repository/browse/maven-public/io/papermc/paper/dev-bundle/
|
|
|
|
fun Project.applyPaperweightAdapterConfiguration(
|
|
|
|
paperVersion: String
|
|
|
|
) {
|
|
|
|
applyCommonConfiguration()
|
|
|
|
apply(plugin = "java-library")
|
|
|
|
applyCommonJavaConfiguration(
|
|
|
|
sourcesJar = true,
|
|
|
|
banSlf4j = false,
|
|
|
|
)
|
|
|
|
apply(plugin = "io.papermc.paperweight.userdev")
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
paperDevBundle(paperVersion)
|
|
|
|
"implementation"(project(":worldedit-bukkit"))
|
|
|
|
}
|
|
|
|
|
|
|
|
tasks.named("assemble") {
|
|
|
|
dependsOn("reobfJar")
|
|
|
|
}
|
|
|
|
}
|