Update start-finalSetup02Modpack (#368)

Fixed curseforge redirect so it actually downloads the JAR file, not an HTML page
This commit is contained in:
Tyler Page 2019-08-02 16:28:35 +00:00 committed by Geoff Bourne
parent e61942f33e
commit e061cc7163

View file

@ -89,7 +89,8 @@ case "X$EFFECTIVE_MANIFEST_URL" in
do do
if [ ! -f $MOD_DIR/${p}_${f}.jar ] if [ ! -f $MOD_DIR/${p}_${f}.jar ]
then then
url="${CURSE_URL_BASE}/${p}/files/${f}/download" redirect_url="$(curl -Ls -o /dev/null -w %{url_effective} ${CURSE_URL_BASE}/projects/${p})"
url="$redirect_url/download/${f}/file"
echo Downloading curseforge mod $url echo Downloading curseforge mod $url
# Manifest usually doesn't have mod names. Using id should be fine, tho # Manifest usually doesn't have mod names. Using id should be fine, tho
curl -sSL "${url}" -o $MOD_DIR/${p}_${f}.jar curl -sSL "${url}" -o $MOD_DIR/${p}_${f}.jar