download from releases instead
This commit is contained in:
+16
-6
@@ -33,12 +33,22 @@ rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \
|
||||
|
||||
# Download translations
|
||||
mkdir -p "rpcs3.app/Contents/translations"
|
||||
curl -fsSL "https://api.github.com/repos/RPCS3/rpcs3_translations/contents/qm" \
|
||||
| grep '"download_url":' \
|
||||
| cut -d '"' -f 4 \
|
||||
| while read -r url; do
|
||||
curl -fsSL "$url" -o "rpcs3.app/Contents/translations/$(basename "$url")"
|
||||
done
|
||||
ZIP_URL=$(curl -fsSL "https://api.github.com/repos/RPCS3/rpcs3_translations/releases/latest" \
|
||||
| grep "browser_download_url" \
|
||||
| grep "RPCS3-languages.zip" \
|
||||
| cut -d '"' -f 4)
|
||||
if [ -z "$ZIP_URL" ]; then
|
||||
echo "Failed to find RPCS3-languages.zip in the latest release. Continuing without translations."
|
||||
else
|
||||
echo "Downloading translations from: $ZIP_URL"
|
||||
curl -L -o translations.zip "$ZIP_URL" || {
|
||||
echo "Failed to download translations.zip. Continuing without translations."
|
||||
exit 0
|
||||
}
|
||||
unzip -o translations.zip -d "rpcs3.app/Contents/translations" >/dev/null 2>&1 || \
|
||||
echo "Failed to extract translations.zip. Continuing without translations."
|
||||
rm -f translations.zip
|
||||
fi
|
||||
|
||||
# Hack
|
||||
install_name_tool -delete_rpath /opt/homebrew/lib RPCS3.app/Contents/MacOS/rpcs3 || echo "Hack for deleting rpath /opt/homebrew/lib not needed"
|
||||
|
||||
Reference in New Issue
Block a user