Summary
Make MAUI Sherpa installable for Windows users via winget and Chocolatey, supporting both x64 and arm64 architectures. This mirrors the existing Homebrew tap automation for macOS.
Current State
- CI already produces
MAUI-Sherpa.win-x64.zip and MAUI-Sherpa.win-arm64.zip as self-contained, unpackaged (exe) distributions
- The
create-release job attaches these ZIPs to GitHub Releases
- The
update-homebrew job auto-updates a Homebrew cask on tag push — the same pattern should be replicated for winget and Chocolatey
Implementation Plan
Phase 1: winget
winget requires a multi-file YAML manifest submitted as a PR to microsoft/winget-pkgs.
Package identity: MAUI.Sherpa
Manifest files (in manifests/m/MAUI/Sherpa/{version}/):
MAUI.Sherpa.yaml — version manifest
MAUI.Sherpa.installer.yaml — installer manifest (x64 + arm64 entries)
MAUI.Sherpa.locale.en-US.yaml — default locale manifest
Installer type: zip — since we ship portable ZIPs containing a self-contained exe, the installer type is zip with a NestedInstallerType: portable and NestedInstallerFiles pointing to MauiSherpa.exe.
Sample installer manifest:
PackageIdentifier: MAUI.Sherpa
PackageVersion: 0.3.0
MinimumOSVersion: 10.0.17763.0
InstallerType: zip
NestedInstallerType: portable
Installers:
- Architecture: x64
InstallerUrl: https://github.com/Redth/MAUI.Sherpa/releases/download/v0.3.0/MAUI-Sherpa.win-x64.zip
InstallerSha256: <computed>
NestedInstallerFiles:
- RelativeFilePath: MauiSherpa.exe
PortableCommandAlias: maui-sherpa
- Architecture: arm64
InstallerUrl: https://github.com/Redth/MAUI.Sherpa/releases/download/v0.3.0/MAUI-Sherpa.win-arm64.zip
InstallerSha256: <computed>
NestedInstallerFiles:
- RelativeFilePath: MauiSherpa.exe
PortableCommandAlias: maui-sherpa
ManifestType: installer
ManifestVersion: 1.10.0
Automation: Add an update-winget job to build.yml that runs on tag push (after create-release):
- Download the x64 and arm64 ZIPs from the release
- Compute SHA256 hashes
- Use
wingetcreate update to generate updated manifests and submit a PR to microsoft/winget-pkgs
- Requires a
WINGET_PAT secret (GitHub PAT with public_repo scope for the winget-pkgs fork)
update-winget:
name: Update winget manifest
runs-on: windows-latest
needs: [create-release]
if: startsWith(github.ref, 'refs/tags/v') && !contains(github.ref, '-')
steps:
- name: Extract version
run: echo "VERSION=$($env:GITHUB_REF -replace 'refs/tags/v','')" >> $env:GITHUB_ENV
- name: Install wingetcreate
run: iwr https://aka.ms/wingetcreate/latest -OutFile wingetcreate.exe
- name: Update manifest and submit PR
run: |
$x64Url = "https://github.com/Redth/MAUI.Sherpa/releases/download/v$env:VERSION/MAUI-Sherpa.win-x64.zip"
$arm64Url = "https://github.com/Redth/MAUI.Sherpa/releases/download/v$env:VERSION/MAUI-Sherpa.win-arm64.zip"
.\wingetcreate.exe update MAUI.Sherpa -v $env:VERSION -u $x64Url $arm64Url -s -t ${{ secrets.WINGET_PAT }}
Phase 2: Chocolatey
Chocolatey uses a .nuspec + PowerShell install scripts, packaged as a .nupkg and pushed to chocolatey.org.
Package ID: maui-sherpa
Approach: Since we distribute portable ZIPs, use Install-ChocolateyZipPackage to download and extract, then Install-BinFile for PATH shimming. Chocolatey downloads the ZIP from the GitHub Release URL at install time (not embedded in the nupkg).
Required files (new directory packaging/chocolatey/):
packaging/chocolatey/
├── maui-sherpa.nuspec
├── tools/
│ ├── chocolateyInstall.ps1
│ ├── chocolateyUninstall.ps1
│ └── VERIFICATION.txt
Sample chocolateyInstall.ps1:
$ErrorActionPreference = 'Stop'
$toolsDir = Split-Path -Parent $MyInvocation.MyCommand.Definition
# Detect architecture
$is64bit = [Environment]::Is64BitOperatingSystem
$isArm = $env:PROCESSOR_ARCHITECTURE -eq 'ARM64' -or $env:PROCESSOR_IDENTIFIER -match 'ARM'
if ($isArm) {
$archSuffix = 'win-arm64'
} else {
$archSuffix = 'win-x64'
}
$url = "https://github.com/Redth/MAUI.Sherpa/releases/download/v$env:chocolateyPackageVersion/MAUI-Sherpa.$archSuffix.zip"
Install-ChocolateyZipPackage -PackageName $env:ChocolateyPackageName `
-Url64bit $url `
-UnzipLocation $toolsDir
Install-BinFile -Name 'maui-sherpa' -Path (Join-Path $toolsDir 'MauiSherpa.exe')
Automation: Add an update-chocolatey job to build.yml:
- Download artifacts, compute checksums
- Update version in
.nuspec template
- Run
choco pack and choco push with CHOCO_API_KEY secret
update-chocolatey:
name: Update Chocolatey package
runs-on: windows-latest
needs: [create-release]
if: startsWith(github.ref, 'refs/tags/v') && !contains(github.ref, '-')
steps:
- uses: actions/checkout@v4
- name: Extract version
run: echo "VERSION=$($env:GITHUB_REF -replace 'refs/tags/v','')" >> $env:GITHUB_ENV
- name: Update nuspec version
run: |
(Get-Content packaging/chocolatey/maui-sherpa.nuspec) -replace '<version>.*</version>', "<version>$env:VERSION</version>" |
Set-Content packaging/chocolatey/maui-sherpa.nuspec
- name: Pack and push
run: |
cd packaging/chocolatey
choco pack
choco push maui-sherpa.$env:VERSION.nupkg --source https://push.chocolatey.org/ --api-key ${{ secrets.CHOCO_API_KEY }}
Phase 3: Secrets and Initial Setup
| Secret |
Purpose |
WINGET_PAT |
GitHub PAT with public_repo scope for submitting PRs to microsoft/winget-pkgs |
CHOCO_API_KEY |
Chocolatey.org API key for pushing packages |
One-time setup:
- winget: Submit the initial manifest PR manually using
wingetcreate new. Subsequent versions are automated.
- Chocolatey: Register the package on chocolatey.org. First push can be done locally with
choco push.
User Experience After Implementation
# winget
winget install MAUI.Sherpa
# Chocolatey
choco install maui-sherpa
Both auto-detect x64 vs arm64 architecture.
Tasks
Summary
Make MAUI Sherpa installable for Windows users via winget and Chocolatey, supporting both x64 and arm64 architectures. This mirrors the existing Homebrew tap automation for macOS.
Current State
MAUI-Sherpa.win-x64.zipandMAUI-Sherpa.win-arm64.zipas self-contained, unpackaged (exe) distributionscreate-releasejob attaches these ZIPs to GitHub Releasesupdate-homebrewjob auto-updates a Homebrew cask on tag push — the same pattern should be replicated for winget and ChocolateyImplementation Plan
Phase 1: winget
winget requires a multi-file YAML manifest submitted as a PR to microsoft/winget-pkgs.
Package identity:
MAUI.SherpaManifest files (in
manifests/m/MAUI/Sherpa/{version}/):MAUI.Sherpa.yaml— version manifestMAUI.Sherpa.installer.yaml— installer manifest (x64 + arm64 entries)MAUI.Sherpa.locale.en-US.yaml— default locale manifestInstaller type:
zip— since we ship portable ZIPs containing a self-contained exe, the installer type iszipwith aNestedInstallerType: portableandNestedInstallerFilespointing toMauiSherpa.exe.Sample installer manifest:
Automation: Add an
update-wingetjob tobuild.ymlthat runs on tag push (aftercreate-release):wingetcreate updateto generate updated manifests and submit a PR tomicrosoft/winget-pkgsWINGET_PATsecret (GitHub PAT withpublic_reposcope for the winget-pkgs fork)Phase 2: Chocolatey
Chocolatey uses a
.nuspec+ PowerShell install scripts, packaged as a.nupkgand pushed to chocolatey.org.Package ID:
maui-sherpaApproach: Since we distribute portable ZIPs, use
Install-ChocolateyZipPackageto download and extract, thenInstall-BinFilefor PATH shimming. Chocolatey downloads the ZIP from the GitHub Release URL at install time (not embedded in the nupkg).Required files (new directory
packaging/chocolatey/):Sample
chocolateyInstall.ps1:Automation: Add an
update-chocolateyjob tobuild.yml:.nuspectemplatechoco packandchoco pushwithCHOCO_API_KEYsecretPhase 3: Secrets and Initial Setup
WINGET_PATpublic_reposcope for submitting PRs tomicrosoft/winget-pkgsCHOCO_API_KEYOne-time setup:
wingetcreate new. Subsequent versions are automated.choco push.User Experience After Implementation
Both auto-detect x64 vs arm64 architecture.
Tasks
microsoft/winget-pkgsupdate-wingetjob to CI workflowpackaging/chocolatey/directory with nuspec and install scriptsupdate-chocolateyjob to CI workflowWINGET_PATandCHOCO_API_KEYrepository secrets