testing update
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -2,19 +2,12 @@
|
|||||||
# Copyright (c) 2023 fithwum
|
# Copyright (c) 2023 fithwum
|
||||||
# All rights reserved
|
# All rights reserved
|
||||||
|
|
||||||
MC_VERSION=1.19.4
|
MC_VERSION="1.19.4"
|
||||||
|
|
||||||
mkdir /mnt/Other/Dockers/minecraft/testing/temp
|
TEST=$(curl -s "https://piston-meta.mojang.com/mc/game/version_manifest_v2.json" | grep -Pom 1 '"url": "\K[^"]*'$MC_VERSION'.json')
|
||||||
|
|
||||||
echo " "
|
echo "Version url: $TEST"
|
||||||
wget --no-cache https://piston-meta.mojang.com/mc/game/version_manifest_v2.json -O /mnt/Other/Dockers/minecraft/testing/temp/mc-versions.json
|
|
||||||
LINE_NUM_1=$(grep -Rne '/mnt/Other/Dockers/minecraft/testing/temp/' -e '"id": "$MC_VERSION"')
|
|
||||||
MC_VERSION_CHECK_1=$(cat /mnt/Other/Dockers/minecraft/testing/temp/mc-versions.json | grep url | head -n$LINE_NUM_1 | awk -F: '{print $3}' | sed 's/[",]//g' | sed "s/checksum//g")
|
|
||||||
#rm -frv /mnt/Other/Dockers/minecraft/testing/temp/mc-versions.json
|
|
||||||
|
|
||||||
wget --no-cache https:${MC_VERSION_CHECK_1} -O /mnt/Other/Dockers/minecraft/testing/temp/server.json
|
MC_VERSION_CHECK=$(curl -s "$TEST" | grep -Pom 1 '"url": "\K[^"]*server.json')
|
||||||
LINE_NUM=$(grep -Rne '/mnt/Other/Dockers/minecraft/testing/temp/' -e '"server"')
|
|
||||||
MC_VERSION_CHECK=$(cat /mnt/Other/Dockers/minecraft/testing/temp/server.json | grep url | head -n$LINE_NUM | awk -F: '{print $3}' | sed 's/[",]//g' | sed "s/checksum//g")
|
|
||||||
#rm -frv /mnt/Other/Dockers/minecraft/testing/temp/server.json
|
|
||||||
|
|
||||||
echo "server url https:$MC_VERSION_CHECK"
|
echo "Server url: $MC_VERSION_CHECK"
|
||||||
Reference in New Issue
Block a user