Skip to content

Commit 4884994

Browse files
Fix the winget submission script
1 parent f03da3f commit 4884994

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

.github/workflows/winget.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,11 @@ jobs:
5656
- PackageIdentifier: Microsoft.PowerShell
5757
MinimumVersion: "7.0.0"
5858
"@
59-
# Insert dependency block before the Installers section
59+
# Remove existing top-level Dependencies block (if any), then insert ours
60+
$content = $content -replace '(?m)^Dependencies:\r?\n([ ]+.+\r?\n)*', ''
6061
$content = $content -replace '(?m)^Installers:', "$dependency`nInstallers:"
6162
Set-Content -Path $installerManifest -Value $content
6263
6364
# Submit the modified manifest
64-
.\wingetcreate.exe submit manifests
65+
$manifestPath = Split-Path $installerManifest
66+
.\wingetcreate.exe submit $manifestPath

0 commit comments

Comments
 (0)