1.21.4 is still experimental
Some checks failed
ci/woodpecker/push/base-cont Pipeline was successful
ci/woodpecker/push/build/2 Pipeline was successful
ci/woodpecker/push/build/3 Pipeline failed
ci/woodpecker/push/build/1 Pipeline was successful
ci/woodpecker/push/discord Pipeline was successful

This commit is contained in:
Ryan Voots 2024-12-24 08:05:50 -05:00
parent 61b0377fdf
commit 96ba49f5e6

View file

@ -5,7 +5,7 @@ set -euxo pipefail
Version=$1
BuildJSON=$(curl -H "Accept-Encoding: identity" -H "Accept-Language: en" -L -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4.212 Safari/537.36" https://api.papermc.io/v2/projects/paper/versions/$Version/builds)
if [[ "${1:-}" == "1.21" ]] ; then
if [[ "${1:-}" == "1.21.4" ]] ; then
Build=$(echo "$BuildJSON" | jq '[.builds[] | select(.channel == "default" or .channel == "experimental")][-1].build')
else
Build=$(echo "$BuildJSON" | jq '[.builds[] | select(.channel == "default")][-1].build')