Fix Windows release packaging: replace rsync/7z with cp/zip
Some checks are pending
Build / Build (arm64) (push) Waiting to run
Build / Build (x86-64) (push) Waiting to run
Build / Build (macOS arm64) (push) Waiting to run
Build / Build (windows-arm64) (push) Waiting to run
Build / Build (windows-x86-64) (push) Waiting to run
Security / CodeQL (C/C++) (push) Waiting to run
Security / Semgrep (push) Waiting to run
Security / Sanitizer Build (ASan/UBSan) (push) Waiting to run

MSYS2 doesn't have rsync or 7z by default. Use cp -r for assets
and install zip package for archive creation.
This commit is contained in:
Kelsi 2026-02-24 05:46:45 -08:00
parent e31c2ffda8
commit 624744da86

View file

@ -249,7 +249,9 @@ jobs:
- name: Install optional packages
shell: msys2 {0}
run: pacman -S --noconfirm --needed ${{ matrix.prefix }}-stormlib || true
run: |
pacman -S --noconfirm --needed ${{ matrix.prefix }}-stormlib || true
pacman -S --noconfirm --needed zip
- name: Configure
shell: msys2 {0}
@ -292,8 +294,14 @@ jobs:
cp tools/asset_pipeline_gui.py "${STAGING}/"
# Assets (exclude proprietary music)
rsync -a --exclude='Original Music' build/bin/assets/ "${STAGING}/assets/" || \
cp -r build/bin/assets "${STAGING}/assets"
mkdir -p "${STAGING}/assets"
for d in build/bin/assets/*/; do
dirname="$(basename "$d")"
[ "$dirname" = "Original Music" ] && continue
cp -r "$d" "${STAGING}/assets/"
done
# Copy top-level asset files
cp build/bin/assets/* "${STAGING}/assets/" 2>/dev/null || true
# Data directory (git-tracked files only)
git ls-files Data/ | while read -r f; do
@ -301,9 +309,8 @@ jobs:
cp "$f" "${STAGING}/$f"
done
# Create ZIP using 7z (available in MSYS2)
7z a -tzip "${STAGING}.zip" "${STAGING}" || \
(cd "${STAGING}" && zip -r "../${STAGING}.zip" .)
# Create ZIP
zip -r "${STAGING}.zip" "${STAGING}"
- name: Upload artifact
uses: actions/upload-artifact@v4