Files
loki/scripts
Mao NakamotoandClaude Opus 4.7 e19a059feb fix(release): mirror script reads workflow artifacts, not the draft release
The v0.3.0 mirror caught a real reliability gap: the draft release on
maonakamoto/fleetcrown only had Linux assets, even though all three matrix
jobs reported success. Likely a race in electron-builder's GH provider
when concurrent matrix jobs publish to the same draft.

Fix: read from the workflow run's artifacts instead. Each matrix job runs
upload-artifact unconditionally with everything it built, so the workflow
artifacts always reflect the complete set — no race, no partial draft.

- Resolves the workflow run ID automatically (latest successful run on the
  fleet-runner-v<version> tag ref) or accepts an explicit run ID arg.
- Flattens the per-OS artifact subdirectories before upload.
- Asserts ≥ 5 assets before publishing (sanity floor — partial uploads
  fail loudly instead of silently mirroring a broken release).

The draft-release path is no longer used and the cleanup hint at the end
now warns the draft is "likely incomplete."

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-06-03 15:14:21 +02:00
..