Skip to content

Commit 3926115

Browse files
committed
fix(vints): assign remotebuild instead of unused remotebuildversion
The API version lookup was setting remotebuildversion but all subsequent jq queries used ${remotebuild}, which was never populated. This caused 'Unable to get remote build' on every install/update.
1 parent a720744 commit 3926115

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lgsm/modules/update_vints.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ fn_update_remotebuild() {
3939
apiurl="http://api.vintagestory.at/stable-unstable.json"
4040
remotebuildresponse=$(curl -s "${apiurl}")
4141
if [ "${branch}" == "stable" ]; then
42-
remotebuildversion=$(echo "${remotebuildresponse}" | jq -r '[ to_entries[] ] | .[].key' | grep -Ev "\-rc|\-pre" | sort -r -V | head -1)
42+
remotebuild=$(echo "${remotebuildresponse}" | jq -r '[ to_entries[] ] | .[].key' | grep -Ev "\-rc|\-pre" | sort -r -V | head -1)
4343
elif [ "${branch}" == "unstable" ]; then
44-
remotebuildversion=$(echo "${remotebuildresponse}" | jq -r '[ to_entries[] ] | .[].key' | grep -E "\-rc|\-pre" | sort -r -V | head -1)
44+
remotebuild=$(echo "${remotebuildresponse}" | jq -r '[ to_entries[] ] | .[].key' | grep -E "\-rc|\-pre" | sort -r -V | head -1)
4545
else
46-
remotebuildversion="${branch}"
46+
remotebuild="${branch}"
4747
fi
4848
remotebuildfilename=$(echo "${remotebuildresponse}" | jq --arg remotebuild "${remotebuild}" -r '.[$remotebuild].linuxserver.filename')
4949
remotebuildurl=$(echo "${remotebuildresponse}" | jq --arg remotebuild "${remotebuild}" -r '.[$remotebuild].linuxserver.urls.cdn')

0 commit comments

Comments
 (0)