From 587adc5ddf979e47e82a5988fe0593097ff50ccd Mon Sep 17 00:00:00 2001 From: Oliver Kieselbach Date: Tue, 18 Aug 2026 03:11:12 +0200 Subject: [PATCH] ci(msi): build from project dir - wix resolves File/@Source against cwd WIX0103 on the first run: Invoke-BootstrapDownload.ps1 not found because wix build resolves File/@Source relative to the working directory, not the wxs location. Matches the local build documented in Package.wxs. Co-Authored-By: Claude Fable 5 --- .github/workflows/build-msi.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-msi.yml b/.github/workflows/build-msi.yml index 4b23f4c7..a0c5b821 100644 --- a/.github/workflows/build-msi.yml +++ b/.github/workflows/build-msi.yml @@ -68,7 +68,12 @@ jobs: - name: Build MSI shell: pwsh run: | - wix build "$env:MSI_PROJECT_DIR/Package.wxs" -arch x64 -o $env:STABLE_MSI + # wix resolves File/@Source relative to the working directory, not the wxs — + # build from inside the project dir (same as the local build documented in the wxs). + $out = Join-Path (Get-Location) $env:STABLE_MSI + Push-Location $env:MSI_PROJECT_DIR + wix build Package.wxs -arch x64 -o $out + Pop-Location if (-not (Test-Path $env:STABLE_MSI)) { Write-Error "wix build produced no MSI"; exit 1 } $sha256 = (Get-FileHash $env:STABLE_MSI -Algorithm SHA256).Hash.ToLowerInvariant() Write-Host "Built $env:STABLE_MSI ($([math]::Round((Get-Item $env:STABLE_MSI).Length / 1KB)) KB)"