PlotSquared/Core/build.gradle.kts

84 lines
2.6 KiB
Plaintext
Raw Permalink Normal View History

2020-10-08 13:27:23 +02:00
import java.time.format.DateTimeFormatter
dependencies {
// Expected everywhere.
2023-08-08 22:33:24 +02:00
compileOnlyApi(libs.checkerqual)
// Minecraft expectations
2023-08-08 22:33:24 +02:00
compileOnlyApi(libs.gson)
compileOnly(libs.guava)
// Platform expectations
2023-08-08 22:33:24 +02:00
compileOnlyApi(libs.snakeyaml)
// Adventure
2023-08-08 22:33:24 +02:00
api(libs.adventureApi)
api(libs.adventureMiniMessage)
// Guice
api(libs.guice) {
2020-10-08 13:27:23 +02:00
exclude(group = "com.google.guava")
}
api(libs.guiceassistedinject) {
2020-10-08 13:27:23 +02:00
exclude("com.google.inject", "guice")
}
api(libs.spotbugs)
2020-10-08 13:27:23 +02:00
// Plugins
2021-11-05 11:57:58 +01:00
compileOnly(libs.worldeditCore) {
2020-10-08 13:27:23 +02:00
exclude(group = "bukkit-classloader-check")
exclude(group = "mockito-core")
exclude(group = "dummypermscompat")
}
testImplementation(libs.worldeditCore)
2023-08-08 22:33:24 +02:00
compileOnly(libs.faweBukkit) { isTransitive = false }
testImplementation(libs.faweCore) { isTransitive = false }
// Logging
2023-08-08 22:33:24 +02:00
compileOnlyApi(libs.log4j)
// Other libraries
api(libs.prtree)
api(libs.aopalliance)
api(libs.cloudServices)
api(libs.arkitektonika)
2023-08-08 22:33:24 +02:00
api(libs.paster)
api(libs.informativeAnnotations)
2020-10-08 13:27:23 +02:00
}
tasks.processResources {
filesMatching("plugin.properties") {
expand(
"version" to project.version.toString(),
"commit" to rootProject.grgit.head().abbreviatedId,
"date" to rootProject.grgit.head().dateTime.format(DateTimeFormatter.ofPattern("yy.MM.dd"))
2020-10-08 13:27:23 +02:00
)
}
doLast {
copy {
from(layout.buildDirectory.file("$rootDir/LICENSE"))
into(layout.buildDirectory.dir("resources/main"))
}
}
}
tasks {
withType<Javadoc> {
2023-01-11 22:11:11 +01:00
val isRelease = if (rootProject.version.toString().endsWith("-SNAPSHOT")) "TODO" else rootProject.version.toString()
val opt = options as StandardJavadocDocletOptions
opt.links("https://docs.enginehub.org/javadoc/com.sk89q.worldedit/worldedit-core/" + libs.worldeditCore.get().versionConstraint.toString())
opt.links("https://jd.advntr.dev/api/" + libs.adventureApi.get().versionConstraint.toString())
opt.links("https://jd.advntr.dev/text-minimessage/" + libs.adventureApi.get().versionConstraint.toString())
opt.links("https://google.github.io/guice/api-docs/" + libs.guice.get().versionConstraint.toString() + "/javadoc/")
opt.links("https://checkerframework.org/api/")
opt.isLinkSource = true
opt.bottom(File("$rootDir/javadocfooter.html").readText())
opt.isUse = true
opt.encoding("UTF-8")
opt.keyWords()
2023-01-11 22:11:11 +01:00
opt.addStringOption("-since", isRelease)
opt.noTimestamp()
}
}