CI: download direct-upload artifacts with download-artifact v8

This commit is contained in:
patchzyy committed 2026-09-03 10:53:45 +02:00
1 parent 7a13696a8b
commit 38a11b7b2c
1 file changed
+10 -9
+10 -9
View File
@@ -123,7 +123,10 @@ jobs:
check Launcher/Build-Installer.ps1 "ProductVersion = '$version'" check Launcher/Build-Installer.ps1 "ProductVersion = '$version'"
exit $status exit $status
- uses: actions/download-artifact@v7 # The build jobs upload with `archive: false`, which stores each installer as a raw file
# rather than a zip (and names the artifact after the file). Only download-artifact v8 and
# later understand such direct uploads; v7 tries to unzip everything and fails on them.
- uses: actions/download-artifact@v8
with: with:
path: artifacts path: artifacts
merge-multiple: true merge-multiple: true
@@ -134,14 +137,12 @@ jobs:
TAG: ${{ github.ref_name }} TAG: ${{ github.ref_name }}
run: | run: |
set -euo pipefail set -euo pipefail
ls -l artifacts ls -lR artifacts
assets=( assets=()
artifacts/WiiCompiled-Setup.exe for name in WiiCompiled-Setup.exe WiiCompiled-Setup-x86_64.AppImage WiiCompiled-Setup-aarch64.AppImage; do
artifacts/WiiCompiled-Setup-x86_64.AppImage found="$(find artifacts -type f -name "$name" | head -n 1)"
artifacts/WiiCompiled-Setup-aarch64.AppImage [ -n "$found" ] && [ -s "$found" ] || { echo "::error::missing release asset $name"; exit 1; }
) assets+=("$found")
for asset in "${assets[@]}"; do
[ -s "$asset" ] || { echo "::error::missing release asset $asset"; exit 1; }
done done
# A re-run of a tag whose release already exists only refreshes the assets. # A re-run of a tag whose release already exists only refreshes the assets.
if gh release view "$TAG" --repo "$GITHUB_REPOSITORY" >/dev/null 2>&1; then if gh release view "$TAG" --repo "$GITHUB_REPOSITORY" >/dev/null 2>&1; then