Update .github/workflows/nightly.yml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Hua Audio 2026-03-09 17:04:44 +01:00 committed by GitHub
parent de6be9921f
commit 8197502a37
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -144,9 +144,21 @@ jobs:
mkdir -p build
gh release download "$TAG" --dir build
echo "Updating rolling 'nightly' release..."
gh release delete nightly --cleanup-tag -y >/dev/null 2>&1 || true
sleep 2
# Download assets from the newly created release if it exists,
# otherwise fall back to using locally built dist/ artifacts.
mkdir -p build
if gh release view "$TAG" >/dev/null 2>&1; then
echo "Downloading assets from GitHub release for $TAG..."
gh release download "$TAG" --dir build
else
echo "GitHub release for $TAG not found; falling back to local dist/ artifacts..."
if [ -d "dist" ]; then
cp -R dist/* build/
else
echo "Error: no GitHub release for $TAG and no local dist/ directory found." >&2
exit 1
fi
fi
gh release create nightly \
--title "Nightly Build" \
--notes "$NOTES" \