File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -36,15 +36,23 @@ jobs:
3636 # Download server files
3737 ./hytale-downloader
3838
39- # Verify jar location (debugging)
40- find . -name "HytaleServer.jar"
39+ # Unzip the downloaded game files (ignoring the downloader zip itself)
40+ # The downloader saves a versioned zip (e.g. 2026...zip)
41+ GAME_ZIP=$(find . -maxdepth 1 -name "*.zip" ! -name "hytale-downloader.zip" | head -n 1)
42+ if [ -n "$GAME_ZIP" ]; then
43+ echo "Extracting $GAME_ZIP..."
44+ unzip -q "$GAME_ZIP"
45+ fi
46+
47+ # Find the jar recursively (structure might be release/package/game/latest/Server or similar)
48+ JAR_PATH=$(find . -name "HytaleServer.jar" | head -n 1)
4149
42- # Install to Maven Local
43- # Note: Path depends on downloader output. Assuming Server/HytaleServer.jar relative to current dir
44- if [ -f "Server/HytaleServer.jar" ]; then
45- mvn install:install-file -Dfile=Server/HytaleServer.jar -DgroupId=com.hypixel.hytale -DartifactId=HytaleServer-parent -Dversion=1.0-SNAPSHOT -Dpackaging=jar
50+ if [ -f "$JAR_PATH" ]; then
51+ echo "Found jar at: $JAR_PATH"
52+ mvn install:install-file -Dfile="$JAR_PATH" -DgroupId=com.hypixel.hytale -DartifactId=HytaleServer-parent -Dversion=1.0-SNAPSHOT -Dpackaging=jar
4653 else
47- echo "Error: HytaleServer.jar not found after download!"
54+ echo "Error: HytaleServer.jar not found after extraction!"
55+ ls -R
4856 exit 1
4957 fi
5058
Original file line number Diff line number Diff line change @@ -30,10 +30,19 @@ jobs:
3030 chmod +x hytale-downloader
3131 ./hytale-downloader
3232
33- if [ -f "Server/HytaleServer.jar" ]; then
34- mvn install:install-file -Dfile=Server/HytaleServer.jar -DgroupId=com.hypixel.hytale -DartifactId=HytaleServer-parent -Dversion=1.0-SNAPSHOT -Dpackaging=jar
33+ GAME_ZIP=$(find . -maxdepth 1 -name "*.zip" ! -name "hytale-downloader.zip" | head -n 1)
34+ if [ -n "$GAME_ZIP" ]; then
35+ echo "Extracting $GAME_ZIP..."
36+ unzip -q "$GAME_ZIP"
37+ fi
38+
39+ JAR_PATH=$(find . -name "HytaleServer.jar" | head -n 1)
40+
41+ if [ -f "$JAR_PATH" ]; then
42+ mvn install:install-file -Dfile="$JAR_PATH" -DgroupId=com.hypixel.hytale -DartifactId=HytaleServer-parent -Dversion=1.0-SNAPSHOT -Dpackaging=jar
3543 else
3644 echo "Error: HytaleServer.jar not found!"
45+ ls -R
3746 exit 1
3847 fi
3948
You can’t perform that action at this time.
0 commit comments