Update dependencies to 1.20.5 and jdk 21

This commit is contained in:
Joo200 2024-04-28 15:32:32 +02:00
parent c65dd83a7e
commit da3c81a88d
5 changed files with 29 additions and 11 deletions

View File

@ -1,5 +1,9 @@
# Changelog
## 7.0.10
* Add support for MC 1.20.5, drop support for other 1.20 versions
## 7.0.9
* Add support for MC 1.20, drop support for MC 1.19
* Made entities spawned via the `/summon` command get treated as plugin-spawned entities

View File

@ -1,11 +1,8 @@
Compiling
=========
You can compile WorldGuard as long as you have some version of Java greater than or equal to 17 installed. Gradle will download JDK 17 specifically if needed,
but it needs some version of Java to bootstrap from.
Note that if you have JRE 17 installed, Gradle will currently attempt to use that to compile, which will not work. It is easiest to uninstall JRE 16 and
replace it with JDK 17.
You can compile WorldGuard as long as you have some version of Java greater than or equal to 21 installed.
Gradle will download JDK 21 specifically if needed, but it needs some version of Java to bootstrap from.
The build process uses Gradle, which you do *not* need to download. WorldGuard is a multi-module project with three modules:

View File

@ -11,7 +11,19 @@ repositories {
dependencies {
implementation(gradleApi())
implementation("gradle.plugin.org.cadixdev.gradle:licenser:0.6.1")
implementation("org.ajoberstar.grgit:grgit-gradle:4.1.1")
implementation("gradle.plugin.com.github.johnrengelman:shadow:7.1.2")
implementation("org.jfrog.buildinfo:build-info-extractor-gradle:4.27.1")
implementation("org.ajoberstar.grgit:grgit-gradle:5.2.2")
implementation("com.github.johnrengelman:shadow:8.1.1")
implementation("org.jfrog.buildinfo:build-info-extractor-gradle:5.2.0")
constraints {
val asmVersion = "[9.7,)"
implementation("org.ow2.asm:asm:$asmVersion") {
because("Need Java 21 support in shadow")
}
implementation("org.ow2.asm:asm-commons:$asmVersion") {
because("Need Java 21 support in shadow")
}
implementation("org.vafer:jdependency:[2.10,)") {
because("Need Java 21 support in shadow")
}
}
}

View File

@ -25,7 +25,7 @@ fun Project.applyCommonConfiguration() {
plugins.withId("java") {
the<JavaPluginExtension>().toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
languageVersion.set(JavaLanguageVersion.of(21))
}
}

View File

@ -12,6 +12,11 @@ repositories {
name = "paper"
url = uri("https://repo.papermc.io/repository/maven-public/")
}
maven {
// TODO: Remove this once paper updated to adventure release
name = "adventure-snapshots"
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
}
}
configurations {
@ -20,8 +25,8 @@ configurations {
dependencies {
"api"(project(":worldguard-core"))
"compileOnly"("io.papermc.paper:paper-api:1.20.4-R0.1-SNAPSHOT")
"runtimeOnly"("org.spigotmc:spigot-api:1.20.4-R0.1-SNAPSHOT") {
"compileOnly"("io.papermc.paper:paper-api:1.20.5-R0.1-SNAPSHOT")
"runtimeOnly"("org.spigotmc:spigot-api:1.20.5-R0.1-SNAPSHOT") {
exclude("junit", "junit")
}
"api"("com.sk89q.worldedit:worldedit-bukkit:${Versions.WORLDEDIT}") { isTransitive = false }