Loading...
Loading...
MSIX packaging, code signing, and distribution for WinUI 3 apps — build for release, certificate generation (winapp cert generate), certificate trust, code signing (winapp sign), self-contained deployment, CI/CD with GitHub Actions, and Microsoft Store submission. Use when preparing for release, creating MSIX installers, managing certificates, setting up CI/CD packaging, or publishing to the Microsoft Store.
npx skill4agent add microsoft/win-dev-skills winui-packaging| Task | Command |
|---|---|
| Build for release | |
| Package + sign | |
| Generate + sign + package | |
| Generate dev certificate | |
| Trust certificate (admin) | |
| Sign existing file | |
| Self-contained deployment | |
winui-dev-workflow.\BuildAndRun.ps1 /p:Configuration=Release -SkipRunwinapp cert generate --manifest .devcert.pfxpassword--manifestPublisherPackage.appxmanifestwinapp cert install ./devcert.pfxwinapp package <build-output-dir> --cert ./devcert.pfxappxmanifest.xmlresources.pri.msix# Local install
Add-AppxPackage ./MyApp.msix
# Or double-click the .msix fileIdentity.Publisherwinapp cert generate --manifestwinapp package --certwinapp signcert installpassword--password--timestampwinapp package <dir> --cert prod.pfx --timestamp http://timestamp.digicert.com--self-containedname: Build and Package
on: [push]
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: microsoft/setup-WinAppCli@v0.1
- name: Build
run: dotnet build -c Release -p:Platform=x64
- name: Package
run: |
winapp cert generate --if-exists skip --quiet
winapp package ./bin/x64/Release/ --cert ./devcert.pfx --quiet
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: msix-package
path: "*.msix"--quiet--if-exists skipcert generate.msix.msixbundlewinapp package| Error | Solution |
|---|---|
| "Publisher mismatch" | Run |
| "Certificate not trusted" | Run |
| "Access denied" | |
| "Certificate file already exists" | Use |
| "appxmanifest.xml not found" | Run |
| "Package installation failed" | Trust cert first; remove stale: |
| Signature invalid after time | Re-sign with |
| File | Read when... |
|---|---|
| Setting up AOT/trimming, JSON source generators, NativeAOT readiness, CsWin32 |