Support experimental builds
This commit is contained in:
parent
565f90192c
commit
119ffbc758
2 changed files with 4 additions and 2 deletions
|
@ -6,7 +6,7 @@ RUN apk add curl jq bash
|
|||
|
||||
LABEL Marc Tönsing <marc@marc.tv>
|
||||
|
||||
ARG version=1.19.3
|
||||
ARG version=1.20.6
|
||||
|
||||
########################################################
|
||||
############## Download Paper with API #################
|
||||
|
|
|
@ -4,7 +4,9 @@
|
|||
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://papermc.io/api/v2/projects/paper/versions/$Version/builds)
|
||||
Build=$(echo "$BuildJSON" | jq '[.builds[] | select(.channel == "default")][-1].build')
|
||||
Build=$(echo "$BuildJSON" | jq '[.builds[] | select(.channel == "default" or .channel == "experimental")][-1].build')
|
||||
|
||||
echo $BuildJSON | jq
|
||||
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" -o paperclip.jar "https://papermc.io/api/v2/projects/paper/versions/$Version/builds/$Build/downloads/paper-$Version-$Build.jar"
|
||||
echo -----------------
|
||||
echo $1#$Build
|
||||
|
|
Loading…
Add table
Reference in a new issue