Skip to content

Commit 5ce6adc

Browse files
committed
More CI fixes
1 parent ba2f651 commit 5ce6adc

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

.github/workflows/jackpot.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454

5555
- name: Bundle
5656
shell: pwsh
57-
run: ls -Recurse ; .\src\Publish-ReleaseBundle.ps1 -MsixX64 "x64/Jackpot-x64.msix" -MsixArm64 "arm64/Jackpot-arm64.msix"
57+
run: .\src\Publish-ReleaseBundle.ps1 -MsixX64 "x64/Jackpot-x64.msix" -MsixArm64 "arm64/Jackpot-arm64.msix"
5858

5959
- name: Upload
6060
uses: actions/upload-artifact@v4

src/Publish-ReleaseBundle.ps1

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,32 @@ param
44
[Parameter(Mandatory = $true)] [string] $MsixArm64
55
)
66

7+
$ErrorPreference = 'Stop'
8+
$ProgressPreference = 'SilentlyContinue'
9+
10+
$root = Split-Path -Path $PSScriptRoot -Parent
11+
712
$bundleDir = "$root\publish\bundle"
813
if (Test-Path $bundleDir) {
914
[System.IO.Directory]::Delete($bundleDir, $true) | Out-Null
1015
}
1116
[System.IO.Directory]::CreateDirectory($bundleDir) | Out-Null
1217

18+
# Windows SDK
19+
$windowsSdkBaseDir = "C:\Program Files (x86)\Windows Kits\10\Redist"
20+
$windowsSdkVersion = `
21+
Get-ChildItem -Path $windowsSdkBaseDir |
22+
Where-Object { $_.Name -match '^10\.0\.\d+\.\d+$' } |
23+
Sort-Object Name -Descending |
24+
Select-Object -First 1 -ExpandProperty Name
25+
26+
$makeappx = "C:\Program Files (x86)\Windows Kits\10\bin\$windowsSdkVersion\x64\makeappx.exe"
27+
if (Test-Path $makeappx) {
28+
Write-Output "MakeAppx: $makeappx"
29+
} else {
30+
throw "MakeAppx not found!"
31+
}
32+
1333
$msixBundleFilePath = "$root\publish\Jackpot.msixbundle"
1434
if (Test-Path $msixBundleFilePath) { Remove-Item -Path $msixBundleFilePath -Force }
1535
Write-Host "`n--- Start: MakeAppx bundle ---"

0 commit comments

Comments
 (0)