mirror of
https://github.com/ViaVersion/VIAaaS.git
synced 2024-11-21 11:55:15 +01:00
Merge pull request #235 from Kichura/master
Update dependencies, Enhance CI and more
This commit is contained in:
commit
ffbb53c326
4
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
4
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
@ -23,12 +23,12 @@ body:
|
||||
attributes:
|
||||
label: Console Error
|
||||
description: |
|
||||
If you encounter warnings/errors in your console, **paste them with https://paste.gg/ and put the paste link here**.
|
||||
If you encounter warnings/errors in your console, **paste them with https://mclo.gs/ and put the paste link here**.
|
||||
If the error is small/less than 10 lines, you may put it directly into this field.
|
||||
There may be some additional information in ``logs/debug.log``
|
||||
value: |
|
||||
```
|
||||
Put the paste.gg link or text here.
|
||||
Put the mclo.gs link or text here.
|
||||
```
|
||||
placeholder: Please do not remove the grave accents; simply replace the line of text in the middle.
|
||||
validations:
|
||||
|
19
.github/workflows/gradle.yml
vendored
19
.github/workflows/gradle.yml
vendored
@ -5,23 +5,26 @@ jobs:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v3
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
distribution: 'temurin'
|
||||
java-version: 17
|
||||
check-latest: true
|
||||
- name: Cache Dependencies
|
||||
uses: actions/cache@v3
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.gradle/
|
||||
key: ${{ runner.os }}-build-aspirin-${{ hashFiles('**/build.gradle.kts') }}
|
||||
path: |
|
||||
~/.gradle/caches
|
||||
~/.gradle/wrapper
|
||||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-aspirin-
|
||||
${{ runner.os }}-gradle-
|
||||
- name: Build with Gradle
|
||||
run: ./gradlew build
|
||||
- name: Upload Artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: artifact
|
||||
name: Artifacts
|
||||
path: build/libs/
|
||||
|
@ -9,15 +9,15 @@ import java.nio.file.Files as JFiles
|
||||
|
||||
buildscript {
|
||||
repositories { mavenCentral() }
|
||||
dependencies { classpath("com.github.hazendaz:htmlcompressor:1.9.1") }
|
||||
dependencies { classpath("com.github.hazendaz:htmlcompressor:2.0.0") }
|
||||
}
|
||||
|
||||
plugins {
|
||||
`java-library`
|
||||
application
|
||||
kotlin("jvm") version "1.9.10"
|
||||
kotlin("jvm") version "1.9.22"
|
||||
id("maven-publish")
|
||||
id("com.github.ben-manes.versions") version "0.47.0"
|
||||
id("com.github.ben-manes.versions") version "0.50.0"
|
||||
id("com.github.johnrengelman.shadow") version "8.1.1"
|
||||
id("com.palantir.git-version") version "3.0.0"
|
||||
id("org.gradlewebtools.minify") version "1.3.2" apply false
|
||||
@ -29,14 +29,14 @@ application {
|
||||
|
||||
java {
|
||||
toolchain {
|
||||
languageVersion.set(JavaLanguageVersion.of(11))
|
||||
languageVersion.set(JavaLanguageVersion.of(17))
|
||||
vendor.set(JvmVendorSpec.ADOPTIUM)
|
||||
}
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
val compileKotlin: KotlinCompile by tasks
|
||||
compileKotlin.kotlinOptions.jvmTarget = "11"
|
||||
compileKotlin.kotlinOptions.jvmTarget = "17"
|
||||
|
||||
val gitVersion: groovy.lang.Closure<String> by extra
|
||||
|
||||
@ -62,14 +62,14 @@ dependencies {
|
||||
|
||||
val vvVer = "4.9.3-SNAPSHOT"
|
||||
val vbVer = "4.9.2-SNAPSHOT"
|
||||
val vrVer = "3.0.5"
|
||||
val vrVer = "3.0.6-SNAPSHOT"
|
||||
implementation("com.viaversion:viaversion:$vvVer") { isTransitive = false }
|
||||
implementation("com.viaversion:viabackwards:$vbVer") { isTransitive = false }
|
||||
implementation("com.viaversion:viarewind-universal:$vrVer") { isTransitive = false }
|
||||
implementation("net.raphimc:ViaAprilFools:2.0.11-SNAPSHOT")
|
||||
implementation("net.raphimc:ViaLegacy:2.2.22-SNAPSHOT")
|
||||
|
||||
val nettyVer = "4.1.99.Final"
|
||||
val nettyVer = "4.1.105.Final"
|
||||
implementation("io.netty:netty-handler-proxy:$nettyVer")
|
||||
implementation("io.netty:netty-resolver-dns:$nettyVer")
|
||||
implementation("io.netty:netty-transport-native-epoll:$nettyVer:linux-aarch_64")
|
||||
@ -79,24 +79,24 @@ dependencies {
|
||||
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.23.Final:linux-aarch_64")
|
||||
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.23.Final:linux-x86_64")
|
||||
|
||||
implementation("com.google.guava:guava:32.0.1-jre")
|
||||
implementation("com.velocitypowered:velocity-native:3.2.0-SNAPSHOT")
|
||||
implementation("com.google.guava:guava:33.0.0-jre")
|
||||
implementation("com.velocitypowered:velocity-native:3.3.0-SNAPSHOT")
|
||||
implementation("net.coobird:thumbnailator:0.4.20")
|
||||
implementation("org.powernukkit.fastutil:fastutil-lite:8.1.1")
|
||||
implementation("org.yaml:snakeyaml:2.2")
|
||||
|
||||
val log4jVer = "2.20.0"
|
||||
val slf4jVer = "2.0.9"
|
||||
val log4jVer = "2.22.1"
|
||||
val slf4jVer = "2.0.11"
|
||||
implementation("com.lmax:disruptor:3.4.4")
|
||||
implementation("net.minecrell:terminalconsoleappender:1.3.0")
|
||||
implementation("org.apache.logging.log4j:log4j-core:$log4jVer")
|
||||
implementation("org.apache.logging.log4j:log4j-iostreams:$log4jVer")
|
||||
implementation("org.apache.logging.log4j:log4j-jul:$log4jVer")
|
||||
implementation("org.apache.logging.log4j:log4j-slf4j2-impl:$log4jVer")
|
||||
implementation("org.jline:jline-terminal-jansi:3.23.0")
|
||||
implementation("org.jline:jline-terminal-jansi:3.25.0")
|
||||
implementation("org.slf4j:slf4j-api:$slf4jVer")
|
||||
|
||||
val ktorVersion = "2.3.5"
|
||||
val ktorVersion = "2.3.7"
|
||||
implementation("io.ktor:ktor-network-tls-certificates-jvm:$ktorVersion")
|
||||
implementation("io.ktor:ktor-server-websockets:$ktorVersion")
|
||||
implementation("io.ktor:ktor-server-netty-jvm:$ktorVersion")
|
||||
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
4
gradlew
vendored
4
gradlew
vendored
@ -200,7 +200,7 @@ fi
|
||||
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
DEFAULT_JVM_OPTS='-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Collect all arguments for the java command:
|
||||
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
|
||||
@ -246,4 +246,4 @@ eval "set -- $(
|
||||
tr '\n' ' '
|
||||
)" '"$@"'
|
||||
|
||||
exec "$JAVACMD" "$@"
|
||||
exec "$JAVACMD" "$@"
|
24
gradlew.bat
vendored
24
gradlew.bat
vendored
@ -34,7 +34,7 @@ set APP_HOME=%DIRNAME%
|
||||
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
|
||||
|
||||
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
||||
set DEFAULT_JVM_OPTS=-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m"
|
||||
|
||||
@rem Find java.exe
|
||||
if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
@ -43,11 +43,11 @@ set JAVA_EXE=java.exe
|
||||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if %ERRORLEVEL% equ 0 goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
|
||||
echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
|
||||
@ -57,11 +57,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
||||
|
||||
if exist "%JAVA_EXE%" goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
|
||||
echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
|
||||
@ -89,4 +89,4 @@ exit /b %EXIT_CODE%
|
||||
:mainEnd
|
||||
if "%OS%"=="Windows_NT" endlocal
|
||||
|
||||
:omega
|
||||
:omega
|
@ -1,7 +1,4 @@
|
||||
jdk:
|
||||
- temurinjdk17
|
||||
before_install:
|
||||
- curl -s "https://get.sdkman.io" | bash
|
||||
- source "$HOME/.sdkman/bin/sdkman-init.sh"
|
||||
- sdk install java 17.0.8+7-tem
|
||||
- sdk use java 17.0.8+7-tem
|
||||
- curl -s "https://get.sdkman.io" | bash
|
||||
- source ~/.sdkman/bin/sdkman-init.sh
|
||||
- sdk install java 17.0.10-tem
|
@ -1,3 +1,3 @@
|
||||
plugins {
|
||||
id("org.gradle.toolchains.foojay-resolver-convention") version "0.5.0"
|
||||
id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0"
|
||||
}
|
@ -6,7 +6,7 @@ import com.viaversion.aas.codec.packet.Packet;
|
||||
import com.viaversion.viaversion.api.protocol.version.ProtocolVersion;
|
||||
import com.viaversion.viaversion.api.type.Type;
|
||||
import com.viaversion.viaversion.libs.opennbt.tag.builtin.Tag;
|
||||
import com.viaversion.viaversion.protocols.protocol1_20_3to1_20_2.util.ComponentConverter;
|
||||
import com.viaversion.viaversion.util.ComponentUtil;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@ -32,13 +32,13 @@ public class AbstractSingleChat implements Packet {
|
||||
|
||||
public JsonElement getMsgAsJson() {
|
||||
if (msg != null) return msg;
|
||||
if (msgTag != null) return JsonParser.parseString(ComponentConverter.tagComponentToJson(this.msgTag).toString());
|
||||
if (msgTag != null) return JsonParser.parseString(ComponentUtil.tagToJson(this.msgTag).toString());
|
||||
return null;
|
||||
}
|
||||
|
||||
public void setMsgForVersion(JsonElement msg, int protocolVersion) {
|
||||
if (protocolVersion >= ProtocolVersion.v1_20_3.getVersion()) {
|
||||
this.msgTag = ComponentConverter.jsonComponentToTag(com.viaversion.viaversion.libs.gson.JsonParser.parseString(msg.toString()));
|
||||
this.msgTag = ComponentUtil.jsonToTag(com.viaversion.viaversion.libs.gson.JsonParser.parseString(msg.toString()));
|
||||
} else {
|
||||
this.msg = msg;
|
||||
}
|
||||
@ -61,4 +61,4 @@ public class AbstractSingleChat implements Packet {
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user