Skip to content

Commit 0d6a676

Browse files
release: handle cimipkg zip asset from cimian-pkg
1 parent afab8d1 commit 0d6a676

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

.github/workflows/release.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,18 @@ jobs:
6868
GH_TOKEN: ${{ github.token }}
6969
run: |
7070
New-Item -ItemType Directory -Path tools -Force | Out-Null
71-
gh release download --repo windowsadmins/cimian-pkg --pattern "cimipkg.exe" --dir tools
71+
$downloaded = $false
72+
try {
73+
gh release download --repo windowsadmins/cimian-pkg --pattern "cimipkg-win-x64.zip" --dir tools 2>$null
74+
if (Test-Path tools/cimipkg-win-x64.zip) {
75+
Expand-Archive -Path tools/cimipkg-win-x64.zip -DestinationPath tools -Force
76+
if (Test-Path tools/cimipkg.exe) { $downloaded = $true }
77+
}
78+
} catch {}
79+
if (-not $downloaded) {
80+
gh release download --repo windowsadmins/cimian-pkg --pattern "cimipkg.exe" --dir tools
81+
}
82+
if (-not (Test-Path tools/cimipkg.exe)) { throw "cimipkg download failed" }
7283
Write-Host "Downloaded: $(Get-Item tools/cimipkg.exe | Select-Object -ExpandProperty Length) bytes"
7384
7485
- name: Build MSI packages

0 commit comments

Comments
 (0)