From 74c9f90e2434a8cdd011556e3c754837d64f94d6 Mon Sep 17 00:00:00 2001 From: Abdessamad Derraz <3028866+Abdess@users.noreply.github.com> Date: Thu, 6 Aug 2026 05:00:50 +0200 Subject: [PATCH] feat: split oversized packs into zip volumes --- .github/workflows/build.yml | 25 +++++++++++++++++++++++-- scripts/generate_site.py | 7 +++++++ 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f168a458..836c8309 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -96,6 +96,21 @@ jobs: if: steps.rate.outputs.skip != 'true' run: python scripts/generate_pack.py --all --output-dir dist/ + - name: Split oversized packs + if: steps.rate.outputs.skip != 'true' + run: | + # GitHub releases cap assets at 2 GB. Use the .zip.001 volume + # convention: 7-Zip and PeaZip open the .001 part directly, + # unlike .partNN names which they reject as corrupt archives. + for f in dist/*.zip; do + size=$(stat -c%s "$f") + if [ "$size" -gt 2000000000 ]; then + split --bytes=1900M --numeric-suffixes=1 --suffix-length=3 "$f" "$f." + rm "$f" + echo "Split $(basename "$f") into $(ls "$f".* | wc -l) parts" + fi + done + - name: Release if: steps.rate.outputs.skip != 'true' run: | @@ -107,9 +122,9 @@ jobs: CHANGES=$(git log --oneline -15 --no-merges -- bios/ platforms/ | sed 's/^/- /') TOTAL=$(python3 -c "import json; print(json.load(open('database.json'))['total_files'])") SIZE=$(python3 -c "import json; print(f'{json.load(open(\"database.json\"))[\"total_size\"]/1024/1024:.0f}')") - PACKS=$(ls dist/*.zip 2>/dev/null | while read f; do echo "- **$(basename $f)** ($(du -m "$f" | cut -f1) MB)"; done) + PACKS=$(ls dist/*.zip dist/*.zip.001 2>/dev/null | while read f; do echo "- **$(basename $f)** ($(du -m "$f" | cut -f1) MB)"; done) - gh release create "$TAG" dist/*.zip \ + gh release create "$TAG" dist/*.zip* \ --repo "${{ github.repository }}" \ --title "BIOS Pack $TAG" \ --notes "${TOTAL} files, ${SIZE} MB, verified checksums. @@ -120,6 +135,12 @@ jobs: ### Install Download the pack matching your frontend, extract to the BIOS directory. + Packs over 2 GB are split into numbered volumes (.zip.001, .zip.002). + Download every part, then either open the .001 file directly with + 7-Zip / PeaZip, or join the parts first: + - Linux/macOS: \`cat PackName.zip.0* > PackName.zip\` + - Windows (cmd): \`copy /b PackName.zip.001+PackName.zip.002 PackName.zip\` + | Platform | Pack | Path | |----------|------|------| | RetroArch / Lakka | RetroArch_Lakka_BIOS_Pack.zip | system/ | diff --git a/scripts/generate_site.py b/scripts/generate_site.py index 93543191..8103bf80 100644 --- a/scripts/generate_site.py +++ b/scripts/generate_site.py @@ -2175,6 +2175,13 @@ Pick the pack that matches the setup from the [releases page]({rel}), download it, and extract the files into the BIOS folder listed below. After extraction, launch a game. If it needed BIOS, it will find it. +Packs over 2 GB are split into numbered volumes (`.zip.001`, `.zip.002`). +Download every part, then open the `.001` file with 7-Zip or PeaZip, which +extract the whole archive directly. To join the parts manually instead: + +- Linux/macOS: `cat PackName.zip.0* > PackName.zip` +- Windows (cmd): `copy /b PackName.zip.001+PackName.zip.002 PackName.zip` + ### Steam Deck | Setup | What it is | Pack | Extract to |