ci(windows): surface the real Expand-Archive failure instead of a swallowed exception

This commit is contained in:
KhooLy 2026-07-30 23:03:16 +03:00
parent 14ab9a0608
commit f9918db942

View file

@ -93,11 +93,20 @@ jobs:
- name: Fetch libVLC runtime
shell: pwsh
run: |
$ErrorActionPreference = "Stop"
$version = "3.0.23"
$archive = "$env:RUNNER_TEMP/vlc-win64.zip"
Invoke-WebRequest "https://get.videolan.org/vlc/$version/win64/vlc-$version-win64.zip" -OutFile $archive
Get-Item $archive | Format-List Name, Length
$extract = "$env:RUNNER_TEMP/vlc-win64"
Expand-Archive $archive -DestinationPath $extract
try {
Expand-Archive $archive -DestinationPath $extract
} catch {
Write-Host "Expand-Archive failed:"
$_ | Format-List * -Force
$_.Exception | Format-List * -Force
throw
}
$root = Get-ChildItem $extract -Directory | Select-Object -First 1
New-Item -ItemType Directory -Force src-tauri/lib/vlc | Out-Null
Copy-Item "$($root.FullName)/libvlc.dll" src-tauri/lib/vlc/