Winui Dev Workflow
Build-and-run loop for WinUI 3 apps: BuildAndRun.ps1, winapp run, build-error fix table
Funguje s nastavením
Co umí
Microsoft's skill for the WinUI 3 / Windows App SDK inner loop: scaffolding a project with `dotnet new winui-mvvm`, building and launching through the bundled BuildAndRun.ps1 (Developer Mode check, x64/ARM64 auto-detect, `winapp run --debug-output`), and diagnosing crashes via WinUI stowed-exception triage. Includes a lookup table mapping concrete error codes (XLS0414, MSB3073, 0x8000FFFF, 0x8007000B, blank window from x:Bind OneTime) to fixes. Triggers when you are building, running, or fixing build/launch errors in a WinUI 3 project. Windows-only: requires PowerShell, .NET SDK, and the winapp CLI.
Testovací report
Cloned the repo and found the skill at plugins/winui/skills/winui-dev-workflow; frontmatter parsed cleanly via yaml.safe_load with exactly name + description, and copying the folder into a temp HOME put SKILL.md at ~/.claude/skills/winui-dev-workflow/SKILL.md. Raw-fetched SKILL.md, BuildAndRun.ps1 and analyzer/Microsoft.WindowsAppSDK.Analyzers.targets — all HTTP 200; I read all 267 lines of BuildAndRun.ps1 and confirmed every one of the six behaviours SKILL.md claims for it (AppModelUnlock registry Developer-Mode check, single-csproj discovery, PROCESSOR_ARCHITECTURE platform detect, dotnet build with /restore, bin\<Platform>\<Config>\net*\win-<rid> output lookup, `winapp run --debug-output`), plus a `finally` block that deletes the temp Directory.Build.props and a guard that refuses to overwrite a pre-existing one. No curl|sh, no base64, no network calls, no secrets, no hardcoded machine paths — only a 49KB prebuilt analyzer DLL whose source lives in-repo at src/tools/winui-analyzer. OUTPUT stage could not be executed: this Mac has no pwsh/powershell, no dotnet, no winapp (`pwsh -File ./BuildAndRun.ps1 -SkipRun` → "command not found"), and the Developer-Mode check reads HKLM, so no build ever ran; I instead wrote two text artifacts (scratchpad/wdw_baseline.md vs wdw_skill.md) for a blank-window + 0x8000FFFF diagnosis — baseline reached for Visual Studio F5, Add-AppxPackage and try/catch around InitializeComponent and listed four speculative blank-window causes, while the skill version replaces the whole loop with one async BuildAndRun.ps1 call, names the single root cause "x:Bind defaults to OneTime — add Mode=OneWay", and adds facts baseline never produced (WINAPP_DBGTOOLS_DIR to skip the first-crash debugger-tools download, MSB3073 XamlCompiler exit-1 = update Microsoft.WindowsAppSDK to >= 2.1.3). Those are documented-content differences, not verified runtime behaviour, so outputMeasured stays false and the verdict is setup. Trigger phrasings judged: SHOULD load — "My WinUI 3 app won't build, I'm getting XLS0414 on a custom control" (yes), "Scaffold a new WinUI 3 desktop app and get it running" (yes), "The Windows App SDK app launches then instantly closes with 0x8000FFFF" (yes); SHOULD NOT — "Sign my MSIX and submit it to the Microsoft Store" (no, that's the sibling winui-packaging skill), "My React Native Windows app fails to build on x64" (no, not WinUI 3). 5/5 correct.
Testováno: 2026-07-21 · Claude Code 2.x (agent harness)
Instalace
git clone --depth 1 https://github.com/microsoft/win-dev-skills.git /tmp/winui-dev-workflow-src mkdir -p ~/.claude/skills cp -R /tmp/winui-dev-workflow-src/plugins/winui/skills/winui-dev-workflow ~/.claude/skills/winui-dev-workflow # Windows-only skill. Runtime prerequisites (not installed by the copy above): # .NET SDK >= 8.0 (10 recommended): winget install Microsoft.DotNet.SDK.10 # winapp CLI >= 0.3: winget install Microsoft.WinAppCLI # WinUI templates: dotnet new install Microsoft.WindowsAppSDK.WinUI.CSharp.Templates # Developer Mode: Settings > System > For developers > On # The skill ships BuildAndRun.ps1 plus a prebuilt analyzer/Microsoft.WindowsAppSDK.Analyzers.dll # (source in the same repo at src/tools/winui-analyzer) that the script injects into your build # via a temporary Directory.Build.props and removes afterwards. # Plugin-marketplace alternative (installs all 7 winui skills + agents): # claude plugin marketplace add microsoft/win-dev-skills && claude plugin install winui@win-dev-skills
Příkazy a ukázkové prompty
/winui-dev-workflowBuild-and-run loop for WinUI 3 apps: BuildAndRun.ps1, winapp run, build-error fix table
Skilly se spouštějí běžnými požadavky — žádné příkazy k zapamatování. Po instalaci ho aktivují prompty jako tyto (anglicky):
Fix this WinUI 3 build errorRun my WinUI app with BuildAndRun.ps1Diagnose why winapp run is failing