- global.json: SDK 10.0.403, so self-contained releases ship the
.NET 10.0.14 runtime (October 2026 security update).
- Microsoft.Extensions.DependencyInjection(.Abstractions) 10.0.13 -> 10.0.14.
- Microsoft.Windows.CsWin32 0.3.366 -> 0.3.367.
- github/codeql-action v4.39.0 -> v4.39.1 (CodeQL and Scorecard uploads),
pinned to the release commit.
- THIRD-PARTY-NOTICES: the new versions and the SonarScanner for .NET.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The app now follows Windows 11: Mica window with its own title bar, a
navigation pane, in-window dialogs, snackbars and the system accent color.
MaterialDesignThemes is gone.
- Shell: resizable FluentWindow (min 960x600) that remembers its size,
position and maximized state. The title bar has a command search box
(Ctrl+K), an admin-session indicator with "End admin session", and a More
menu. The pane has Home, Favorites, History, Recipes, My commands and the
catalog with its twelve categories and counts; the selection stays in sync
with the view-model through NavigationKey.
- MainViewModel keeps the shell only; the catalog's browsing, filters,
detail and run logic moved to CatalogViewModel. The catalog gets risk and
admin-only filter chips, the estimated duration and an expanded command
line in the detail panel, and a splitter between detail and console.
- One shared console for catalog, recipes and user commands: virtualized,
batched, capped at 10,000 lines with a "N earlier lines" note, Copy all,
Save to file, "Waiting for administrator permission…" status and Restart
now (asks first, never while a command runs).
- Confirmation, update and bug-report dialogs are Fluent content dialogs;
Cancel stays the default and Run appears for a Dangerous command only
once its name or id is typed. The Legal Gate, terms viewer, crash dialog
and command palette are Fluent windows; the Legal Gate lets you pick the
language first.
- Theme: light, dark or system through ApplicationThemeManager, accent from
Windows, High Contrast always wins. Font size scales every text and
control live. Pages set the theme text color themselves (the navigation
frame doesn't pass it down), and list text dims instead of recoloring so
it stays readable on a selected row; search matches are bold and
underlined.
- A finished run notifies with a snackbar (and flashes the taskbar button)
when the console isn't visible; the taskbar shows progress while running.
- Catalog icons map to Fluent System Icons (IconMap), checked by a test.
- The presentation namespace is now CommandForge.Desktop: a namespace named
CommandForge.Wpf hid WPF-UI's root namespace in XAML-generated code. The
project, assembly and exe keep the name CommandForge.Wpf.
- IElevationService raises SessionChanged when the elevated helper starts or
stops.
- Strings: about 45 new keys in all five languages; twelve unused keys
removed. A test now scans the UI sources so every key the XAML or code
uses must exist in every language.
BREAKING CHANGE: new look and layout; settings, history, recipes and user
commands carry over unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
New tests for the output decoder (UTF-8, UTF-16LE with and without BOM,
OEM fallback, chunk boundaries), executable resolution, argument tokens,
the elevated child environment (including a real PowerShell run showing
it loads modules only from admin-only folders), crash-safe JSON files and
v1.5.1 settings, accent-insensitive search, recipe confirmations, the
update dialog, the console buffer and crash codes.
Run faults and cancellation must complete the output channel; elevation
tests have time limits; the DI test uses a scratch folder instead of the
real %AppData%; culture-switching tests run on their own; Domain and
Application may reference only the runtime (and Domain).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every log event made the Log Viewer and Debug panel rebuild up to 1000
rows on the UI thread. The in-memory store now raises EntriesChanged once,
150 ms after the first event of a burst; Clear still notifies at once.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A command is registered only after it passes validation, so a rejected
command can no longer be a revert target or shadow a valid duplicate, and
a revert that points at one is cleared. New checks: unknown argument
tokens, an executable that is not a plain program name, Caution or
Dangerous without confirmBeforeRun, Launch mode with an exit-code or
output restart policy, and a restartRegex under another policy. Invalid
embedded JSON yields an empty catalog plus an error instead of a crash.
The catalog tests also enforce -NoProfile -NonInteractive for PowerShell,
no wmic, no hard-coded C:, no %VAR% outside scripts, and that elevated
scripts read only the environment variables the Elevator sets from
trusted sources. DangerLevel documents what Safe, Caution and Dangerous
mean.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Automatic Disk Cleanup now enables an allow-list of safe handlers in its
own StateFlags slot (/sagerun:42), so Downloads, the Recycle Bin and
Windows.old are never touched and the user's own /sageset:1 choice is
kept. Removing Windows.old uses the "Previous Installations" handler and
is now Dangerous, as is clearing the event logs.
- Every PowerShell command runs with -NoProfile -NonInteractive. Scripts
that printed success no matter what now stop on the first error, and
cleanups report what they removed and what was in use.
- chkdsk.fix uses Repair-Volume -OfflineScanAndFix instead of piping a
"Y" that is localized; drive letters come from {SystemDrive} and the
battery report path from {UserProfile}.
- Windows Update reset keeps the old folders as .bak copies and always
restarts the services; the Delivery Optimization cache uses its cmdlet;
lid-close settings apply to the active power scheme; winget never
prompts; activation status no longer needs VBScript; the Win11 Widgets
button opens Settings, since Windows now blocks that change from scripts.
- New: restore point list, System Restore, Automatic Maintenance, clock
resync, DNS cache, listening ports, Wi-Fi details, third-party scheduled
tasks, Run keys, stopped automatic services, Windows Search restart,
Store and optional updates, UAC settings, Core isolation, environment
variables, WSL status, TRIM status, crash dumps and battery charge, with
strings in all five languages.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Download and apply are separate steps: applying first ends the elevated session and waits for the
Elevator to exit (it runs from the folder Velopack replaces, and the non-elevated updater can't
kill it or overwrite its locked files), and a command started during the download postpones the
restart instead of being killed halfway.
- UpdateErrorMapper.Map(Exception) looks through wrapper/aggregate exceptions for the HTTP status;
HttpClient timeouts now map to Offline instead of being rethrown as cancellations (which left the
dialog stuck on "Checking"). User cancellation is still distinguished.
- Closing the update dialog with its title-bar X cancels the download; otherwise it finished in the
background and restarted the app, possibly mid-command.
- The startup prompt never opens over another dialog; the "command running" guard reads the shared
ExecutionViewModel (now a singleton) instead of MainWindow.DataContext.
- Settings' "Last checked" only updates when a check actually succeeded.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
All six JSON stores (config, history, recipes, profiles, user commands, settings import/export)
go through a shared JsonFile helper:
- Writes land in a temporary file that atomically replaces the original, so a crash or power loss
mid-save can no longer truncate config.json (which silently reset every setting, including the
accepted terms) or wipe history/recipes/profiles.
- A corrupt file is kept as name.corrupt-<timestamp>.json before defaults are used, instead of
being overwritten on the next save; locked or unreadable files no longer crash startup.
- Background save failures are logged rather than thrown; a user-chosen export path still
reports its error, and import files are never renamed.
- Every store serializes access with a lock and hands out copies, not its live list.
- config.json uses a source-generated serializer with the same PascalCase/enum-name format; loads
repair null lists, unknown enum values and blank ids.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Program.Main runs VelopackApp.Build().Run() before WPF loads App.xaml (Velopack's own
recommendation; vpk warned about OnStartup), then the single-instance check.
- The unused Generic Host (no hosted services, configuration or Microsoft.Extensions.Logging
consumers) is replaced by a validated ServiceCollection; Microsoft.Extensions.Hosting and
Serilog.Extensions.Hosting are dropped (~20 transitive packages).
- A startup failure now shows an error and exits instead of leaving an invisible process that held
the single-instance mutex and silently swallowed every later launch; a malformed language code in
config.json falls back to the system language.
- Serilog: 14 daily files of at most 10 MB (logs grew without bound before); flushed after the
container is disposed so shutdown logging is kept.
- Second launches pass foreground rights to the running instance (AllowSetForegroundWindow) so it
actually comes to the front instead of flashing in the taskbar.
- Crash handler: stable support codes (FNV-1a instead of the per-process randomized
string.GetHashCode), a nested failure no longer closes the logger for the rest of the session,
and the error dialog only takes an owner window that is visible.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Elevated children get an allow-listed environment rebuilt from trusted sources: per-user
variables (COR_PROFILER/CORECLR_* DLL injection, PSModulePath module hijacking, windir/
SystemRoot retargeting of recursive deletes) no longer reach commands run as administrator.
PSModulePath is $PSHOME\Modules only, the one value Windows PowerShell 5.1 keeps as-is.
- Both ends verify the peer: the UI accepts only the Elevator process it launched
(GetNamedPipeClientProcessId); the Elevator serves only CommandForge.Wpf.exe from its own folder
(GetNamedPipeServerProcessId) and connects with Identification impersonation.
- The Elevator writes no files any more (an elevated append to the user-writable profile could be
redirected with a junction); diagnostics go back to the UI's log as pipe Log messages.
- StartupHookSupport=false on the Elevator: DOTNET_STARTUP_HOOKS is ignored.
- Broker: cancelling while UAC/connecting returns Cancelled instead of throwing; a command that
ignores a cancel for 10 s ends the session; pipe/JSON errors fail the run cleanly; the output
channel is always completed.
- IElevationService: IsSessionActive and EndSessionAsync (needed before an update replaces the
files the elevated process runs from) replace the unused IsElevationAvailable.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- ExecutableResolver: catalog executables resolve to absolute paths in System32/Windows (and
the winget alias), so CreateProcess never searches the per-user, user-writable app folder —
a planted reg.exe/powershell.exe there would otherwise run elevated. Launch-mode commands now
pin their working directory too.
- OutputDecoder: stdout/stderr are read as raw bytes and decoded per line (UTF-16LE when the
stream is UTF-16, else strict UTF-8 with an OEM-code-page fallback). sfc/wsl output and every
native tool on Vietnamese/Japanese/Chinese Windows used to show as mojibake. Lone \r (progress
updates) still breaks lines.
- ProcessJob: captured commands join a kill-on-close job object, so closing or crashing the app
can no longer leave a half-finished command running.
- ArgumentTokens ({SystemDrive}, {SystemRoot}, {UserProfile}) filled from SystemPaths, which reads
the kernel-reported system directory, known folders and HKLM — never %SystemRoot%-style
variables a standard user can redefine. The command preview shows the expanded values.
- Exit code 3010 always flags a restart; Launch commands honour RestartPolicy.Always; output is
only captured (bounded) when a restart regex needs it. ExecutionResult.OutputLines is gone
(nothing read it, and it held the entire output in memory).
- RunCommandUseCase always completes the output channel and maps cancellation, so a failing run
can no longer leave the console waiting forever.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
GitHub's dependency graph reads NuGet versions from .csproj files but not from
Directory.Packages.props, so Central Package Management would have blinded Dependabot alerts,
dependency review and the release SBOM. Versions move back into the projects (same versions),
SonarAnalyzer.CSharp is now referenced from Directory.Build.props, and the xUnit v3 test
project declares OutputType Exe explicitly.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- UpdateViewModel: every check/download owns a disposed CancellationTokenSource that Close
cancels; an unexpected exception now shows an error instead of leaving the dialog on "Checking".
- Regex calls (catalog validation, restart detection) run with a match timeout.
- Elevation: CancelAsync/DisposeAsync instead of the blocking variants; implementations declare
the interface's default CancellationToken.
- SystemProcessRunner: drop the redundant blocking WaitForExit (WaitForExitAsync already drains
redirected output); "Restart now" launches System32\shutdown.exe by absolute path.
- ProductLinks: one home for the repository/issue/license/user-guide URLs that were duplicated
across five files (the dead wiki link now points at the user guide).
- Smaller rule fixes (readonly fields, LINQ filters, no empty loops, nested ternaries, static
handlers); remove the unused LegalGateViewModel.TermsVersion.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Directory.Packages.props: Central Package Management for every project; SonarAnalyzer.CSharp
as a global analyzer so the build enforces the same rules as SonarCloud.
- Directory.Build.props: NuGet audit of direct + transitive packages (moderate+ advisories fail the
build), deterministic CI paths, dev version 2.0.0.
- global.json: .NET SDK 10.0.402 (latest LTS feature band).
- Bumps: Microsoft.Extensions.* 10.0.13, Serilog 4.4.0, Velopack 1.2.161, CsWin32 0.3.366,
Microsoft.NET.Test.Sdk 18.11.0, coverlet.collector 10.1.0, xunit 2.9.3 -> xunit.v3 4.0.2 (VSTest
mode) + xunit.runner.visualstudio 4.0.1.
- The Elevator publish now inherits PublishReadyToRun from the app publish.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Launching CommandForge.Wpf.exe repeatedly opened a new window each time
because there was no single-instance guard. Add SingleInstanceGuard (a
WPF-free Infrastructure primitive) that owns a session-scoped named mutex;
a later launch signals the primary via a named auto-reset event and exits,
and the primary restores + foregrounds its existing window.
- Guard is created right after VelopackApp.Build().Run() so install/update
hook processes are never counted as a second instance.
- Activation marshals to the UI dispatcher; SetForegroundWindow beats the
Windows foreground lock. MainWindow is NoResize so Normal fully restores it.
- Adds unit tests for primary/secondary detection, activation signalling and
name reclamation; CHANGELOG updated for 1.5.1.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds 40 rarely-used and Windows-version-specific commands across 9 existing
categories: 5 Windows 10-only (maxOsBuild 19045 — the first use of maxOsBuild
gating in the catalog), 11 Windows 11-only (minOsBuild 22000+, incl. 3 for
24H2/26100), and 24 rare cross-version diagnostics/info/security/dev commands.
Each command is wired with Cmd_<id>_Title/_Desc keys in all five resource
cultures (en, vi, ja, zh-Hans, es); reg-based HKCU tweaks include
affectedRegistryValues and confirmBeforeRun for Caution entries.
Also fixes TPM Status (info.tpm) and Defender Exclusions
(sec.defender.exclusions): both now require admin so their queries
(Get-CimInstance on MicrosoftTpm / Get-MpPreference) return data instead of
appearing blank — they run in-process without elevation today.
Adds CommandDefinitionTests coverage for maxOsBuild gating (Win10-only
commands hidden on Windows 11, visible on Windows 10).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
New 12th category "services-startup" plus a storage/maintenance-heavy batch.
- services-startup (8, NEW category): restart Print Spooler / Windows Audio /
Windows Update / BITS services; list running & automatic services; open
Startup apps settings; open the Startup folder
- storage (5): largest temp files, list partitions, analyze fragmentation
(read-only), configure Disk Cleanup (sageset), list disks & volumes (diskpart)
- cleanup (3): clear icon cache, clear recent items, clear event logs
- power (2): Power Saver plan, hibernate now
- system-maintenance (2): online disk scan (Repair-Volume -Scan), verify
system files (sfc /verifyonly)
categories.json gains services-startup (order 12); CatalogTests category-count
assertion bumped 11 -> 12. All keys localized across EN/VI/JA/zh-Hans/ES.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Visibility batch: system diagnostics & info that only read state or open a
console — zero Caution/Dangerous commands, ideal smoke-test set.
- system-info (7): battery health, network adapter speed, disk health,
page file usage, local user accounts, time zone, Windows install date
- network (6): public DNS lookup test, active TCP connections, firewall
profiles, shared folders, show hosts file, Network Connections (ncpa.cpl)
- diagnostics (5): recent boot/shutdown events, unexpected shutdowns
(Kernel-Power 41), recent system errors, Print Management, Certificate Manager
- storage (2): drive usage summary, disk SMART status
All keys localized across EN/VI/JA/zh-Hans/ES. Catalog stays at 11 categories.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Grows the catalog from 116 to 141 commands and adds an 11th category,
"Storage". All new commands are vetted, fixed catalog entries (no user
interpolation); admin ones run via the Elevator. No new Dangerous commands.
New category: storage (Optimize/defrag C:, Disk Management, list volumes
and free space, open Storage settings).
Other additions across existing groups:
- system-info: TPM status, Secure Boot state, computer & OS summary.
- network: network adapters, DNS servers, internet connectivity test.
- diagnostics: startup programs, Driver Verifier, Performance Monitor,
system health report.
- cleanup: clear crash dumps, Windows Error Reporting, DNS+ARP caches.
- power: lid-close action and monitor-timeout toggles (revert pairs).
- tweaks-shortcuts: NumLock-at-startup and verbose sign-in toggles
(revert pairs, with affectedRegistryValues).
Localization: 51 new keys (50 command + Cat_storage) added to all five
languages (EN authored; VI/JA/zh-Hans/ES machine-translated, flagged for
native review). ResxKeyTests enforces full parity.
Tests: CatalogTests category count 10 -> 11; added guards for the Storage
category and for "Dangerous commands must confirm". 195/195 passing.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds optional minOsBuild/maxOsBuild to a command; the WPF catalog
projection hides commands that do not apply to the current OS build, so
Windows 11-only tweaks never appear on Windows 10 (and vice-versa).
- Domain: CommandDefinition gains MinOsBuild/MaxOsBuild + the pure
AppliesToOsBuild(build) predicate (no Win32 dependency).
- Infrastructure: CommandDto maps the fields; CatalogLoader validates
positive values and maxOsBuild >= minOsBuild. ICatalogProvider still
returns the full set, so the Debug panel and tests are unaffected.
- WPF: CatalogViewModelBuilder.Build(catalog, osBuild) filters once,
centrally — covering the list, palette, category counts and every
dashboard. The OS build comes from the existing ISystemInfoService.
- Catalog: gate the Win11 context-menu, taskbar-alignment and
clock-seconds tweaks (minOsBuild 22000 / 22621).
Tests: AppliesToOsBuild theory + catalog range/positive validation;
189 pass. App launches without startup regressions.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds 38 vetted, embedded commands spanning system-info, network,
tweaks, cleanup, power, diagnostics, updates, security and developer
groups — e.g. installed updates/drivers/BIOS/apps/monitors,
netstat/arp/route/wifi/proxy, dark-mode + Win11 taskbar/clock tweaks,
thumbnail/font/prefetch cleanup, balanced plan + power requests +
fast-startup toggle, Task/Device/Services consoles + gpresult, winget
sources + Store reset, Defender status/full-scan, firewall on/off,
WSL shutdown, Sandbox off, long-paths toggle.
- Reversible tweaks wired as set↔revert pairs; dev.sandbox.on now links
to the new dev.sandbox.off.
- EN + VI resource keys added for every command (ResxKeyTests enforces
both with no fallback).
- Win11-only tweaks (taskbar*, clockseconds*) ship ungated here; the
OS-build version-flag mechanism follows in a separate change.
All 167 tests pass.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Post-v1.1.0 fixes reported from testing.
- User commands hanging on cmd: SystemProcessRunner now redirects and
immediately closes stdin, so an interactive process (e.g. "cmd" with
no /c) gets EOF and exits instead of blocking forever. Additionally,
UserCommandFactory.NormalizeArguments prepends /c for cmd (e.g. "cmd"
+ "ping google.com" -> "cmd /c ping google.com") so the command runs
and exits; the run confirmation shows the effective command line.
PowerShell and other executables are unchanged.
- Recipes: AddStep no longer adds a command already in the chain, so a
recipe never runs one command multiple times.
- Sidebar: hide the vertical scrollbar on the command-groups list.
- Tests for the cmd /c normalization (cmd/cmd.exe/path, existing /c|/k,
powershell, empty args) + ToDefinition applying it.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Implements C6 + C2 from docs/Extra.md Part 2, with a safe design that
preserves the Elevator invariant (no new privileged write path).
- Catalog: optional affectedRegistryValues field (RegistryValueRef in
Domain + DTO + mapping), declared on tweak.showext / tweak.showhidden.
- Application: IRegistryService (read-only) + pure RegistrySnapshot
(Capture + Diff -> RegistryChange).
- Infrastructure: WindowsRegistryService over Microsoft.Win32.Registry;
unknown hive / missing key / access error all read as null.
- WPF: after a run with affectedRegistryValues, MainViewModel re-reads
the values and appends a localized before/after diff to the console.
- Undo (C2): History entries whose command has a vetted RevertCommandId
get an "Undo" button that runs that catalog revert command — NO
arbitrary registry writes, the Elevator still only accepts catalog ids.
- EN/VI .resx; docs (Changelog/roadmap/Security.md §4).
- Tests: snapshot diff (null/changed), Win32 read smoke (known/missing/
bad hive), and the catalog schema field.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Implements B1 from docs/Extra.md Part 1, safety-critical (golden rule #1).
- Domain: UserCommand (id/name/executable/arguments).
- Application: IUserCommandStore port + UserCommandFactory.ToDefinition,
which FORCES RequiresAdmin=false and namespaces the id as "user:" so
it can never be routed to — or accepted by — the Elevator.
- Infrastructure: JsonUserCommandStore -> %AppData%\CommandForge\
user-commands.json, fully separate from the embedded catalog. No
telemetry; corrupt-file fallback.
- WPF: new "My commands" section (sidebar + View menu) with a persistent
warning banner. Create/edit/save/delete; Run shows the exact command
line and that it runs without admin, then executes asInvoker via the
forced-non-elevated definition. Console bound to the shared execution.
- EN/VI .resx; docs/Security.md §2.1 (threat model).
- Tests: ToDefinition never RequiresAdmin, id is namespaced, the
definition routes to the executor (never elevation), store round-trip.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Implements B2 from docs/Extra.md Part 1 (Macro / recipe).
- Domain: Recipe (named, ordered list of catalog command ids).
- Application: IRecipeStore port + pure RecipeFlow.ShouldStop
(stop on failure / cancel / reboot-required).
- Infrastructure: JsonRecipeStore -> %AppData%\CommandForge\recipes.json
(source-gen, schema version, corrupt-file fallback). No telemetry;
recipes reference only vetted catalog ids.
- WPF: ExecutionViewModel.RunRecipeAsync runs steps sequentially
through the same broker session (one UAC for an all-admin chain),
streaming a per-step header and stopping per RecipeFlow. New Recipes
shell section (sidebar + View menu) with RecipesViewModel/RecipesView:
build/reorder/remove steps from the catalog, save/delete recipes, and
Run with a single aggregated confirmation (warns on dangerous steps).
Each finished step is recorded in the execution history.
- EN/VI .resx keys; tests for RecipeFlow and the recipe store.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Implements C3 + C4 from docs/Extra.md Part 2.
- Application: PortableSettings (machine-portable subset: appearance,
behavior, favorites) + pure SettingsTransfer (Capture/Apply);
ISettingsFile (import/export) and IProfileService ports.
- Infrastructure: JsonSettingsFile (read/write a chosen .json) and
JsonProfileService -> %AppData%\CommandForge\profiles.json, both via
a shared source-gen context with a schema version + corrupt-file
fallback. No telemetry; import never carries executable commands.
- WPF: new Settings "Backup & profiles" section — Export/Import
buttons and a named-profile picker (apply/delete + save-current).
Import/apply route appearance/language/font through the existing
observable-property setters (live apply + persist); favorites are
written to settings and the shell re-syncs via a new
SettingsViewModel.PortableSettingsApplied event.
- EN/VI .resx keys; tests for capture/apply round-trip, file
round-trip/fallbacks, and profile CRUD/persistence.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds a local execution history (C1 from docs/Extra.md Part 2).
- Domain ExecutionRecord; Application IExecutionHistoryService port +
pure ExecutionHistory helper (newest-first, cap 200, no de-dupe).
- Infrastructure JsonExecutionHistoryService -> %AppData%\CommandForge\
history.json (source-gen context, schema version, corrupt-file
fallback). No telemetry.
- ExecutionViewModel exposes LastResult; MainViewModel records each
finished, non-cancelled run via IClock + the history service.
- New History shell section (sidebar button + View menu) with
HistoryViewModel/HistoryView: per-run time/status/duration, "Run
again" (re-runs through the normal confirm/elevation flow) and
"Clear history". Runs of commands removed from the catalog show
their id and cannot be re-run.
- EN/VI .resx keys; tests for the cap helper and JSON round-trip /
fallbacks.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Completes Phase 5 (Polish):
- Home dashboard (default screen): recent commands, pinned favorites,
and a read-only system-status widget (Windows + build, RAM, system
drive, uptime) via ISystemInfoService. Status is read locally with
no process spawn, no elevation and no network (golden rules).
- Favorites: pin/unpin from the list + detail star, persisted by id in
config.json; a Favorites sidebar item filters the catalog to pins.
- Recent commands: last 10 run command ids tracked for Home.
- Window placement: persist + restore size/position/maximized, clamped
to the virtual screen so a stale multi-monitor position never lands
off-screen.
- Accessibility: AutomationProperties.Name on new controls + palette
and confirmation inputs; heading semantics on Home; Ctrl+H opens Home.
Implementation notes:
- ISystemInfoService uses Environment.OSVersion + CsWin32
GlobalMemoryStatusEx + DriveInfo + TickCount64 (AllowUnsafeBlocks for
the generated interop).
- Pure, unit-tested helpers RecentCommands.Add / Favorites.Toggle and
WindowPlacement.IsOnScreen.
- 102 tests pass; 0-warning Release build.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Foundation slice of Phase 5 (polish):
- Settings model: AppTheme/FontScale enums + 9 new ISettingsService settings
(theme, language, font size, sidebar/badges, confirm-caution, restore point,
auto-scroll, warn-on-cancel), persisted to config.json (string enums).
- Runtime i18n, no restart: LocalizationManager (INotifyPropertyChanged indexer) +
LocExtension now returns a live Binding, so {res:Loc} flips language instantly;
catalog display strings refresh in place on culture change.
- ThemeService (Light/Dark/System via MaterialDesign PaletteHelper, tracks OS) and
FontScaleService (AppFontSize DynamicResource); applied at startup from settings.
- In-shell navigation: MainWindow content swaps between CatalogView (extracted) and
a new SettingsView via CurrentSection; opened by the sidebar gear / View menu / Ctrl+,.
- Settings screen: Appearance (live theme/lang/font + sidebar/badges), Behavior &
Safety (Dangerous-confirm locked on), Updates (auto-check + Check now + version),
About (version, GPLv3/GitHub links, "no data collected"). EN/VI strings + a11y names.
- Consumption: confirmation honors ConfirmCaution (Dangerous always confirms); restore
point, auto-scroll, warn-on-cancel, sidebar-collapse and badges read the settings.
Tests: settings round-trip + defaults, LocalizationManager culture flip, Settings UI
key coverage EN/VI. 58 tests pass; 0-warning Release build; clean startup smoke.
Diagnostics (Log Viewer/Debug/crash handler) are 5b; Home/favorites/full a11y are 5c.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
vpk verifies VelopackApp.Build().Run() is present in the main executable. Calling
it via VelopackBootstrap (Infrastructure) failed that check ("Unable to verify
VelopackApp is called"), so call it directly in App.OnStartup and reference
Velopack from the WPF project. Removes the now-unused VelopackBootstrap. Also fix
pack.ps1 --mainExe to CommandForge.Wpf.exe (the actual published exe name).
Verified: scripts/pack.ps1 -Version 0.3.0 with vpk 1.2.0 produces
CommandForge-win-Setup.exe + *-full.nupkg + RELEASES; the Elevator is bundled.
53 tests still pass.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add the update path per the roadmap: IUpdateService -> VelopackUpdateService
(GithubSource against the project repo; per-user install, no UAC), a minimal
"Check for updates" dialog (check -> prompt -> progress -> apply & restart),
mapped error dialogs (404/403/429/5xx/offline; 419 is not special-cased), an
"auto-check on startup" setting, and scripts/pack.ps1 for vpk packaging.
- Application stays Velopack-free: UpdateError, UpdateCheckResult, pure
UpdateErrorMapper, widened IUpdateService, CheckForUpdateUseCase.
- Infrastructure: VelopackUpdateService (lazy manager, degrades to NotInstalled
in dev) + VelopackBootstrap so the WPF layer never references Velopack.
- WPF: UpdateViewModel/UpdateDialog, IUpdateDialogService, Tools menu item,
VelopackApp.Build().Run() at startup + non-blocking auto-check, gated on the
Phase 3 "command running" guard before applying.
- Tests: error mapping (429 handled, 419 -> Unknown), use-case pass-through,
DI resolution.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add the remaining commands from the catalog spec across system-maintenance,
updates-packages, tweaks-shortcuts, network, cleanup, power, diagnostics,
security-privacy and developer. Multi-step and file-deletion commands are fixed
single `powershell -NoProfile -Command "..."` entries (no new execution
capability), respecting the read-only embedded catalog (golden rule #1). EN/VI
.resx title/description keys added for every new command.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Elevator pipe server: accepts only a commandId, validates it against its OWN
embedded catalog (id exists + requiresAdmin), runs via ProcessCommandExecutor,
streams output, supports mid-run cancel. Never builds a command from pipe input.
- Pipe: per-session GUID name + current-user DACL; UI is the pipe server
(medium IL), Elevator connects as client (high IL) to avoid the integrity barrier.
- BrokerElevationService: spawns the Elevator once per session via runas (one UAC),
relays Run/Cancel and streamed output; graceful UAC-declined handling.
- RunCommandUseCase routes admin commands to the broker, others in-process.
- 6 Safe admin commands (DISM CheckHealth/ScanHealth/Analyze, chkdsk read,
BitLocker status, Windows features) + EN/VI strings; system-maintenance populated.
- Wpf copies CommandForge.Elevator.exe next to the app (build + publish).
- Security hardening (from review): pin process WorkingDirectory to System32 so a
bare executable name can't resolve from an attacker-controlled CWD when elevated.
- Tests: pipe protocol round-trip, ElevationServer over an in-process named pipe
(fakes), admin/non-admin routing (35 total).
Build -c Release: 0 warnings. dotnet test: 35/35. UAC flow verified manually.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>