Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
83 commits
Select commit Hold shift + click to select a range
65100e7
Add `.csproj` project mode to `winapp run`
nmetulev Jul 17, 2026
f4f217b
Re-trigger CI after rebase onto main
nmetulev Jul 17, 2026
aded63a
Support .sln/.slnx solution input for winapp run
nmetulev Jul 17, 2026
4935693
Use Path.Join for arch dir + temp test dir
nmetulev Jul 17, 2026
9781da2
Address pr-review findings for winapp run project mode
nmetulev Jul 17, 2026
d39f2fa
Refactor: address pr-review Tier 3 findings (L2, M9, M5)
nmetulev Jul 18, 2026
077f08f
Auto-inject CsWinRTWindowsMetadata when no Windows SDK is registered
nmetulev Jul 18, 2026
a656248
run: fail fast on packaged-only options for unpackaged apps (#676)
nmetulev Jul 18, 2026
fbee3b7
Address Copilot PR review (C1, C2, C6) on run project mode
nmetulev Jul 18, 2026
31a7c70
Fix CI build: resolve analyzer warnings treated as errors in tests
nmetulev Jul 18, 2026
4d66556
Auto-select runnable project from a solution/directory, skipping tests
nmetulev Jul 18, 2026
f4e91ed
Address Copilot review: guard fully-qualified selector, LINQ nits
nmetulev Jul 18, 2026
2939b9e
Add winui-solution sample for run solution-mode auto-selection
nmetulev Jul 20, 2026
c570674
Discover owning solution for bare-csproj runs so $(SolutionDir) is de…
nmetulev Jul 20, 2026
04c9c5b
Restore owning solution's build-dependency siblings before build (NET…
nmetulev Jul 21, 2026
6d4b7ed
run: convey project-mode arch via RID only (fix PRI252/MSB3030 on mul…
nmetulev Jul 21, 2026
bed5859
Address pr-review findings for csproj/sln project mode
nmetulev Jul 21, 2026
4e1e4a3
Address Copilot review: pass-consistent props, highest version, cance…
nmetulev Jul 21, 2026
f95d7c3
Address follow-up Copilot review: restore-pass precedence + cancellation
nmetulev Jul 21, 2026
6b88ae4
Address Copilot review: honor cancellation in SDK/packaging probes an…
nmetulev Jul 21, 2026
925bc05
Address Copilot review: classify under effective build inputs; cancel…
nmetulev Jul 21, 2026
462c8dd
Address Copilot review round 5 (C13-C16)
nmetulev Jul 21, 2026
9ac7e01
Address Copilot review cycle 6 (C17-C23)
nmetulev Jul 21, 2026
de58c16
Address Copilot review (cycle 7): conditional TFM, restore fallback, …
nmetulev Jul 21, 2026
6f692f3
Address Copilot review cycle 8 (project-mode run)
nmetulev Jul 21, 2026
da229d5
Fix winui-unpackaged-app sample test: exercise a truly cold project-m…
nmetulev Jul 21, 2026
ca7d430
Merge branch 'main' into nmetulev-run-csproj-project-mode
nmetulev Jul 22, 2026
9c3456a
Address Copilot review cycle 9 (C31, C32) on winapp run project mode
nmetulev Jul 22, 2026
c00fbf3
Address Copilot review cycle 10 (C33, C34) on winapp run project mode
nmetulev Jul 22, 2026
045895f
Add end-to-end architecture-gate tests for PackageRegistrationService…
nmetulev Jul 22, 2026
a76d66e
Fix C36: force JSON envelope in effective-TFM discovery evaluate
nmetulev Jul 22, 2026
30123e3
Address Copilot review cycle 13 (C37, C40)
nmetulev Jul 22, 2026
60c5a84
Address Copilot review cycle 14 (C41, C42)
nmetulev Jul 22, 2026
1dd3b3d
Address Copilot review cycle 15 (C43): honor --no-restore in unpackag…
nmetulev Jul 22, 2026
4b9a42c
Address Copilot review cycle 16 (C44): lone non-runnable csproj stays…
nmetulev Jul 22, 2026
86506b6
Extract MSBuild argument construction into ProjectRunService.Argument…
nmetulev Jul 22, 2026
133d8dc
Polish winapp run project-mode output (UX feedback)
nmetulev Jul 22, 2026
97361ec
Fix multi-TFM candidate misclassification + verbosity test drift
nmetulev Jul 22, 2026
5795d5d
Merge branch 'main' into nmetulev-run-csproj-project-mode
nmetulev Jul 22, 2026
7e9b36d
Remove specs/ folder and fix run build-spinner blank line
nmetulev Jul 22, 2026
b5f0ab1
Address Copilot review: WinApp run-support packaging signal + honor -…
nmetulev Jul 22, 2026
68bca8f
Fix cancellation process-tree leak and lone-test note bypassing outpu…
nmetulev Jul 22, 2026
61ac109
Resolve owning solution before lone-project classification; dedup sol…
nmetulev Jul 22, 2026
257879b
test(run): cover runtime gates, cross-arch install-skip, arch + rejec…
nmetulev Jul 22, 2026
223fb36
Address PR #612 LOW review items (L1-L5)
nmetulev Jul 22, 2026
10ef18b
Address PR #612 review comments: cancel-await, sln folder fallback, v…
nmetulev Jul 22, 2026
e19b903
Fix winapp run build spinner flooding the terminal (revert to Status)
nmetulev Jul 22, 2026
26ea3c0
Fix winapp run build spinner: 2-row live region (no flood, no blank l…
nmetulev Jul 22, 2026
eaa2424
Stream winapp run build output live and always print the dotnet invoc…
nmetulev Jul 23, 2026
39e42e2
run: use dotnet's native terminal logger for interactive builds
nmetulev Jul 23, 2026
ed77bd2
Add pre-build spinner for winapp run project mode
nmetulev Jul 23, 2026
8f8ee9b
Show a spinner during pre-build project resolution
nmetulev Jul 23, 2026
014096d
run: honor bare -p:TargetFramework and ignore conditional test marker…
nmetulev Jul 23, 2026
c6282e3
run: reject non-Windows RIDs in --runtime and document arch-only redu…
nmetulev Jul 23, 2026
ba3e575
run: only pass --no-restore to `dotnet list package` on .NET 10+ SDKs
nmetulev Jul 23, 2026
0bf1279
run: TFM last-wins + share explicit framework across passes; --runtim…
nmetulev Jul 23, 2026
9ce6f41
run: launch app in caller cwd like dotnet run; rename positional arg …
nmetulev Jul 23, 2026
240b5a7
npm: keep deprecated `inputFolder` alias for run() after input-folder…
nmetulev Jul 23, 2026
29de2bf
Trim verbose comments across project-mode code
nmetulev Jul 23, 2026
ad2e3b7
Fix runtime resolution for apps referencing WinAppSDK without the met…
nmetulev Jul 23, 2026
787fd7c
Print launch confirmation for unpackaged project-mode runs
nmetulev Jul 23, 2026
6313a44
Fix 3 PR review findings in project-mode run
nmetulev Jul 24, 2026
88d8cc6
Address Zach's PR review (H1, M1, M2) + coverage (M3, M4)
nmetulev Jul 24, 2026
8fff1db
Address PR #612 review round 3 (H1/H2/M1–M5/L1)
nmetulev Jul 24, 2026
5becbeb
Gate name-based sample cleanup on the launch phase
nmetulev Jul 24, 2026
b0e4c34
Potential fix for pull request finding
nmetulev Jul 24, 2026
f961be9
Merge origin/main into nmetulev-run-csproj-project-mode
nmetulev Jul 27, 2026
871053f
Merge remote-tracking branch 'origin/nmetulev-run-csproj-project-mode…
nmetulev Jul 27, 2026
f56cf6f
Revert --property to ZeroOrMore arity (undo autofix b0e4c34f)
nmetulev Jul 27, 2026
9a860d2
Fix: inject -p:Platform for projects declaring <Platforms> (AnyCPU re…
nmetulev Jul 28, 2026
e72fadf
Exclude analyzer/build-only ProjectReferences from Platform-injection…
nmetulev Jul 28, 2026
33b78d3
Address PR #612 review: input classification & pre-build gate (F1, F5…
nmetulev Jul 29, 2026
0c7a839
Address PR #612 review: launch messaging (F2, F3, F4)
nmetulev Jul 29, 2026
754864d
Address PR #612 review: --no-build RID fallback + F1 gate wiring (F10…
nmetulev Jul 29, 2026
cfab195
Address PR #612 review: runtime provisioning honesty + pkglist tradeo…
nmetulev Jul 29, 2026
ba0eb1d
Address PR #612 review: hide passthrough arg from generated docs (cop…
nmetulev Jul 29, 2026
db35ff8
Fix F1/F10 found by validating PR #612 fixes against the reviewers' a…
nmetulev Jul 29, 2026
7c91581
Fix "a arm64 machine" grammar in the F2 cross-arch launch message
nmetulev Jul 29, 2026
bc02ee9
Tighten docs and comments: drop rework narration, fix a stale claim
nmetulev Jul 29, 2026
31e3fd5
Docs: remove two nonexistent flags, trim a security-design essay
nmetulev Jul 29, 2026
15b9ed8
Merge branch 'main' into nmetulev-run-csproj-project-mode
nmetulev Jul 30, 2026
5d32906
Decide RID injection from the project graph instead of always injecti…
nmetulev Jul 30, 2026
2ef0614
Merge branch 'main' into nmetulev-run-csproj-project-mode
nmetulev Jul 30, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 20 additions & 8 deletions .claude/agents/winapp.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ Does the project already have an appxmanifest.xml?
│ └─ winapp package <build-output-dir>
│ (add --cert ./devcert.pfx to sign in one step)
├─ Need package identity for debugging Windows APIs?
│ ├─ Have a .NET/WinUI .csproj or .sln/.slnx (or a folder with one)? (build + run in one step)
│ │ └─ winapp run <project-or-solution> (dotnet build + provision runtime + launch)
│ │ (packaged apps launch with identity; unpackaged apps launch the .exe directly, no identity)
│ ├─ Is the exe in the same folder as your build output? (most frameworks)
│ │ └─ winapp run <build-output-dir> (registers loose layout + launches)
│ └─ Is the exe separate from your app code? (Electron, sparse package testing)
Expand Down Expand Up @@ -133,18 +136,27 @@ Want to inspect or interact with a running app's UI?
- `--no-install` — create but don't register the package
**Requires:** `appxmanifest.xml` + path to your built `.exe`

### `winapp run <input-folder>`
**Purpose:** Create a loose layout package from a build output folder, register it with Windows via `Add-AppxPackage`, and launch the app — simulating a full MSIX install for debugging.
**When to use:** The **preferred command** for iterative development and debugging with package identity. Use this whenever your exe lives inside the build output folder (most .NET, C++, Rust, Flutter, Tauri projects).
### `winapp run [<input>]`
**Purpose:** Build and/or package a Windows app and launch it — for **packaged** apps this simulates a full MSIX install with package identity; for **unpackaged** apps it launches the built `.exe` directly (no package identity). Returns the launched process ID for debugger attachment. Operates in one of two modes, auto-selected from the input:
- **Folder mode** — input is a build-output folder (contains `Package.appxmanifest`/`AppxManifest.xml`). Creates a loose-layout package, registers it with Windows, and launches it. Original behavior, unchanged.
- **Project mode** — input is a `.csproj`, a `.sln`/`.slnx` solution, or a directory containing one (including `.`). Builds the project with `dotnet build`, installs the matching-architecture Windows App Runtime if the app uses the Windows App SDK, then launches it. Supports both **packaged** (`WindowsPackageType=MSIX` → loose-layout + AUMID) and **unpackaged** (`WindowsPackageType=None` → launch the built `.exe` directly) WinUI apps, detected from the effective `WindowsPackageType` MSBuild property. Input defaults to the current directory when omitted (like `dotnet run`). Requires .NET SDK 8.0.100+.
**When to use:** The **preferred command** for iterative development and debugging with package identity (.NET, C++, Rust, Flutter, Tauri). Point it at a project/solution to build-and-run in one step, or at a build-output folder to package-and-run existing output.
**Key options:**
- `--manifest <path>` — path to `appxmanifest.xml` (default: auto-detect)
- `--args <string>` — command-line arguments to pass to the app
- `--no-launch` — register the package without launching
- `--manifest <path>` — path to `appxmanifest.xml` (folder mode and packaged project mode; default: auto-detect)
- `--args <string>` — command-line arguments to pass to the app. Alternatively pass app args after `--` (e.g., `winapp run . -- --flag value`)
- `--no-launch` — register/prepare without launching
- `--with-alias` — launch via execution alias (console apps run in current terminal)
- `-c, --configuration <name>` — (project mode) build configuration; default `Debug`
- `--arch <x64|arm64|x86>` — (project mode) target architecture; default: current process arch. Sets both the build RID and the Windows App Runtime arch
- `-r, --runtime <rid>` — (project mode) target .NET RID (e.g. `win-x64`); **only the RID's architecture is used** — project mode reduces it and always builds the canonical `win-<arch>` RID, so a version-specific or non-Windows RID is not forwarded (a non-Windows RID like `linux-x64` is rejected). Overrides `--arch`.
- `-f, --framework <tfm>` — (project mode) target framework for multi-targeted projects
- `--project <name-or-path>` — (project mode) select which project to launch when a solution/directory has multiple runnable app projects (errors listing candidates if ambiguous)
- `--no-build` / `--no-restore` — (project mode) skip build / restore
- `-p, --property <Name=Value>` — (project mode) MSBuild property forwarded to build + evaluation; repeatable (e.g. `-p WindowsPackageType=None`)
- `--debug-output` — capture `OutputDebugString` messages and first-chance exceptions (prevents other debuggers like VS/VS Code from attaching). For WinUI apps it also auto-runs a stowed-exception (`0xC000027B`) triage pass (`!xamlstowed`/`!xamltriage`) that recovers the originating HRESULT and native XAML dispatch stack. The first triage run downloads debugger components (engine bits from NuGet + `JsProvider.dll` from the WinDbg CDN) and caches them under `~\.winapp\dbgtools\`; if downloads are blocked, install Debugging Tools for Windows or point `WINAPP_DBGTOOLS_DIR` at a debugger directory containing `dbgeng.dll` and `JsProvider.dll`.
- `--symbols` — with `--debug-output`, download Microsoft public symbols for richer native crash stacks (first run downloads and caches them)
- `--output-appx-directory <path>` — custom output directory for loose layout
**Requires:** Built app output directory + `appxmanifest.xml`
- `--output-appx-directory <path>` — custom output directory for the loose layout
**Requires:** Folder mode — built app output directory + `appxmanifest.xml`. Project mode — a `.csproj`/`.sln`/`.slnx` (or directory containing one) + .NET SDK 8.0.100+.

### `winapp cert generate`
**Purpose:** Create a self-signed PFX certificate for local testing.
Expand Down
38 changes: 34 additions & 4 deletions .claude/skills/winapp-setup/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,29 @@ winapp run ./bin/Debug --debug-output

Use `winapp run` during iterative development — it creates a loose layout package, registers a debug identity, and launches the app in one step. For identity-only registration without loose layout, use `winapp create-debug-identity` instead.

#### Project mode: `winapp run` on a `.csproj` (.NET / WinUI)

For .NET SDK projects you can point `winapp run` **at the project instead of the build output** — it builds the `.csproj` and launches it in one step, so there's no separate `dotnet build` and no need to know the output path:

```powershell
# Build and run the project in the current directory (input defaults to ".")
winapp run

# Run a specific project, configuration, and architecture
winapp run ./src/MyApp/MyApp.csproj -c Release --arch arm64

# Force an unpackaged run of a packaged project
winapp run . -p WindowsPackageType=None

# Show winapp's build decision traces (dotnet build stays at minimal verbosity)
winapp run . --verbose
```

Project mode supports both **packaged** and **unpackaged** WinUI apps, detected from the project's effective `WindowsPackageType` (`MSIX` ⇒ loose-layout register + AUMID launch; `None` ⇒ launch the built `.exe`), and installs the matching-architecture Windows App Runtime before launching. Requires .NET SDK 8.0.100+.

- **Build inputs:** `-c/--configuration`, `--arch`, `-r/--runtime`, `-f/--framework`, `--no-build`, `--no-restore`, `-p/--property` (repeatable).
- **Packaged-only options:** `--manifest`, `--no-launch`, `--with-alias`, `--clean`, `--unregister-on-exit`, `--output-appx-directory`, `--executable` — rejected for unpackaged apps.
- **Output:** winapp prints the exact `dotnet build …` invocation, then streams build output live (warnings included on success). Under `--json`/`--quiet` both go to **stderr** so stdout stays clean.

#### Choosing between `run` and `create-debug-identity`

Expand Down Expand Up @@ -213,28 +236,35 @@ Check for and install newer SDK versions. Updates winapp.yaml with latest versio

### `winapp run`

Creates packaged layout, registers the Application, and launches the packaged application.
Builds and runs a Windows app from a .csproj/.sln or a build-output folder. In project mode, invokes dotnet build then launches the app (packaged or unpackaged); in folder mode, creates a debug-signed layout, registers the package, and launches it.

#### Arguments
<!-- auto-generated from cli-schema.json -->
| Argument | Required | Description |
|----------|----------|-------------|
| `<input-folder>` | Yes | Input folder containing the app to run |
| `<app-args>` | No | Arguments to pass to the launched application. Provide after -- (e.g., winapp run . -- --flag value). |
| `<input>` | No | Path to the app to run: a build-output folder, a .csproj project, a .sln/.slnx solution, or a directory containing one of those at its top level (default: current directory). |

#### Options
<!-- auto-generated from cli-schema.json -->
| Option | Description | Default |
|--------|-------------|---------|
| `--arch` | Project mode: target architecture (x64, arm64, or x86). Ignored in folder mode. Default: the current process architecture. | (none) |
| `--args` | Command-line arguments to pass to the application. Alternatively, use -- followed by arguments to avoid escaping (e.g., winapp run . -- --flag value). | (none) |
| `--clean` | Remove the existing package's application data (LocalState, settings, etc.) before re-deploying. By default, application data is preserved across re-deployments. | (none) |
| `--configuration` | Project mode: build configuration (e.g., Debug, Release). Ignored in folder mode. Default: Debug. | `Debug` |
| `--debug-output` | Capture OutputDebugString messages and first-chance exceptions from the launched application. Only one debugger can attach to a process at a time, so other debuggers (Visual Studio, VS Code) cannot be used simultaneously. Use --no-launch instead if you need to attach a different debugger. For WinUI apps, a crash also triggers a stowed-exception triage pass; the first run downloads debugger components (cached under the winapp global directory) and can be pointed at an existing debugger install via the WINAPP_DBGTOOLS_DIR environment variable. Cannot be combined with --no-launch or --json. | (none) |
| `--detach` | Launch the application and return immediately without waiting for it to exit. Useful for CI/automation where you need to interact with the app after launch. Prints the PID to stdout (or in JSON with --json). | (none) |
| `--executable` | Path to the executable relative to the input folder. Use to disambiguate when the manifest contains a $targetnametoken$ placeholder and multiple .exe files are present in the input folder. | (none) |
| `--framework` | Project mode: target framework moniker for multi-targeted projects (e.g. net10.0-windows10.0.26100.0). Ignored in folder mode. | (none) |
| `--json` | Format output as JSON | (none) |
| `--manifest` | Path to the Package.appxmanifest (default: auto-detect from input folder or current directory) | (none) |
| `--no-build` | Project mode: skip building and run the existing build output (still evaluates output properties). Ignored in folder mode. | (none) |
| `--no-launch` | Only create the debug identity and register the package without launching the application | (none) |
| `--output-appx-directory` | Output directory for the loose layout package. If not specified, a directory named AppX inside the input-folder directory will be used. | (none) |
| `--no-restore` | Project mode: skip restoring the project before building. Ignored in folder mode. | (none) |
| `--output-appx-directory` | Output directory for the loose layout package. If not specified, a directory named AppX inside the input directory will be used. | (none) |
| `--project` | Project mode: when the input is a solution (.sln/.slnx) or a directory with multiple runnable app projects, selects which project to launch (by name or path). Ignored in folder mode. | (none) |
| `--property` | Project mode: MSBuild property as Name=Value, forwarded to both build and evaluation. Repeatable (e.g. -p WindowsPackageType=None). Ignored in folder mode. | (none) |
| `--runtime` | Project mode: target .NET runtime identifier (RID), e.g. win-x64. Project mode uses only the RID's architecture, always builds the canonical win-<arch>, and rejects non-Windows RIDs (e.g. linux-x64); it overrides --arch. Ignored in folder mode. | (none) |
| `--symbols` | Download symbols from Microsoft Symbol Server for richer native crash analysis, including the WinUI stowed-exception dispatch stack. Only used with --debug-output. First run downloads symbols and caches them locally; subsequent runs use the cache. | (none) |
| `--unregister-on-exit` | Unregister the development package after the application exits. Only removes packages registered in development mode. | (none) |
| `--with-alias` | Launch the app using its execution alias instead of AUMID activation. The app runs in the current terminal with inherited stdin/stdout/stderr. Requires a uap5:ExecutionAlias in the manifest. Use "winapp manifest add-alias" to add an execution alias to the manifest. | (none) |
28 changes: 20 additions & 8 deletions .github/plugin/agents/winapp.agent.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ Does the project already have an appxmanifest.xml?
│ └─ winapp package <build-output-dir>
│ (add --cert ./devcert.pfx to sign in one step)
├─ Need package identity for debugging Windows APIs?
│ ├─ Have a .NET/WinUI .csproj or .sln/.slnx (or a folder with one)? (build + run in one step)
│ │ └─ winapp run <project-or-solution> (dotnet build + provision runtime + launch)
│ │ (packaged apps launch with identity; unpackaged apps launch the .exe directly, no identity)
│ ├─ Is the exe in the same folder as your build output? (most frameworks)
│ │ └─ winapp run <build-output-dir> (registers loose layout + launches)
│ └─ Is the exe separate from your app code? (Electron, sparse package testing)
Expand Down Expand Up @@ -134,18 +137,27 @@ Want to inspect or interact with a running app's UI?
- `--no-install` — create but don't register the package
**Requires:** `appxmanifest.xml` + path to your built `.exe`

### `winapp run <input-folder>`
**Purpose:** Create a loose layout package from a build output folder, register it with Windows via `Add-AppxPackage`, and launch the app — simulating a full MSIX install for debugging.
**When to use:** The **preferred command** for iterative development and debugging with package identity. Use this whenever your exe lives inside the build output folder (most .NET, C++, Rust, Flutter, Tauri projects).
### `winapp run [<input>]`
**Purpose:** Build and/or package a Windows app and launch it — for **packaged** apps this simulates a full MSIX install with package identity; for **unpackaged** apps it launches the built `.exe` directly (no package identity). Returns the launched process ID for debugger attachment. Operates in one of two modes, auto-selected from the input:
- **Folder mode** — input is a build-output folder (contains `Package.appxmanifest`/`AppxManifest.xml`). Creates a loose-layout package, registers it with Windows, and launches it. Original behavior, unchanged.
- **Project mode** — input is a `.csproj`, a `.sln`/`.slnx` solution, or a directory containing one (including `.`). Builds the project with `dotnet build`, installs the matching-architecture Windows App Runtime if the app uses the Windows App SDK, then launches it. Supports both **packaged** (`WindowsPackageType=MSIX` → loose-layout + AUMID) and **unpackaged** (`WindowsPackageType=None` → launch the built `.exe` directly) WinUI apps, detected from the effective `WindowsPackageType` MSBuild property. Input defaults to the current directory when omitted (like `dotnet run`). Requires .NET SDK 8.0.100+.
**When to use:** The **preferred command** for iterative development and debugging with package identity (.NET, C++, Rust, Flutter, Tauri). Point it at a project/solution to build-and-run in one step, or at a build-output folder to package-and-run existing output.
**Key options:**
- `--manifest <path>` — path to `appxmanifest.xml` (default: auto-detect)
- `--args <string>` — command-line arguments to pass to the app
- `--no-launch` — register the package without launching
- `--manifest <path>` — path to `appxmanifest.xml` (folder mode and packaged project mode; default: auto-detect)
- `--args <string>` — command-line arguments to pass to the app. Alternatively pass app args after `--` (e.g., `winapp run . -- --flag value`)
- `--no-launch` — register/prepare without launching
- `--with-alias` — launch via execution alias (console apps run in current terminal)
- `-c, --configuration <name>` — (project mode) build configuration; default `Debug`
- `--arch <x64|arm64|x86>` — (project mode) target architecture; default: current process arch. Sets both the build RID and the Windows App Runtime arch
- `-r, --runtime <rid>` — (project mode) target .NET RID (e.g. `win-x64`); **only the RID's architecture is used** — project mode reduces it and always builds the canonical `win-<arch>` RID, so a version-specific or non-Windows RID is not forwarded (a non-Windows RID like `linux-x64` is rejected). Overrides `--arch`.
- `-f, --framework <tfm>` — (project mode) target framework for multi-targeted projects
- `--project <name-or-path>` — (project mode) select which project to launch when a solution/directory has multiple runnable app projects (errors listing candidates if ambiguous)
- `--no-build` / `--no-restore` — (project mode) skip build / restore
- `-p, --property <Name=Value>` — (project mode) MSBuild property forwarded to build + evaluation; repeatable (e.g. `-p WindowsPackageType=None`)
- `--debug-output` — capture `OutputDebugString` messages and first-chance exceptions (prevents other debuggers like VS/VS Code from attaching). For WinUI apps it also auto-runs a stowed-exception (`0xC000027B`) triage pass (`!xamlstowed`/`!xamltriage`) that recovers the originating HRESULT and native XAML dispatch stack. The first triage run downloads debugger components (engine bits from NuGet + `JsProvider.dll` from the WinDbg CDN) and caches them under `~\.winapp\dbgtools\`; if downloads are blocked, install Debugging Tools for Windows or point `WINAPP_DBGTOOLS_DIR` at a debugger directory containing `dbgeng.dll` and `JsProvider.dll`.
- `--symbols` — with `--debug-output`, download Microsoft public symbols for richer native crash stacks (first run downloads and caches them)
- `--output-appx-directory <path>` — custom output directory for loose layout
**Requires:** Built app output directory + `appxmanifest.xml`
- `--output-appx-directory <path>` — custom output directory for the loose layout
**Requires:** Folder mode — built app output directory + `appxmanifest.xml`. Project mode — a `.csproj`/`.sln`/`.slnx` (or directory containing one) + .NET SDK 8.0.100+.

### `winapp cert generate`
**Purpose:** Create a self-signed PFX certificate for local testing.
Expand Down
Loading
Loading