Skip to content

Bootstrap Falcon BMS Config editor (WPF, .NET Framework 4.8) - #1

Merged
arithex merged 1 commit into
mainfrom
claude/affectionate-goodall-gn2lqa
Oct 29, 2026
Merged

arithex merged 1 commit into
mainfrom
claude/affectionate-goodall-gn2lqa

Conversation

@arithex

@arithex arithex commented Oct 29, 2026

Copy link
Copy Markdown
Owner

First version of the cfg editor described in CLAUDE.md. The build produces a single Config.exe for .NET Framework 4.8, AnyCPU with 64-bit preferred. It has no runtime dependencies beyond Windows and .NET Framework.

Core (src/BmsConfig/Core/)

  • CfgDocument parses and edits a cfg file line by line. It keeps comments, blank lines, unrecognized lines and ordering exactly as they were. An edit replaces only the value, so whitespace and the trailing comment stay. New lines go just above the Launcher cut line in User.cfg. Files are read as UTF-8 with or without a BOM, and written without one. Original line endings are kept.
  • ValueConverter handles:
    • the datatype, taken from the g_b / g_n / g_f / g_s prefix of the name;
    • Range:[min-max] and Range:[0-] limits, and Enum:[...] labels;
    • hex input for integers (0x...);
    • rejecting exponents, NaN and Infinity in float input;
    • stripping straight, curly or single quotes that users paste around strings;
    • checking the 4 feature-flag params against their regexes.
  • ConfigSet merges Falcon BMS.cfg, then User.cfg, then VR.cfg, with the last writer winning. Params that aren't in Falcon BMS.cfg are filed under "Other". Before each save, the target file is re-read from disk, so a change another tool made in the meantime isn't lost. The feature flags can be written only to Falcon BMS.cfg.
  • BmsInstalls reads HKLM\SOFTWARE\WOW6432Node\Benchmark Sims through the 32-bit registry view, so the lookup works for both 32-bit and 64-bit processes.

UI

  • The master/detail layout follows the mockups. It has the install dropdown, which defaults to the install that contains Config.exe, and Open Folder. If no cfg files are found, a file dialog lets the user locate them. A cfg file can also be dragged onto the window.
  • The filter bar has search, a category filter, "Modified only" and "Include VR overrides". Clicking a column header sorts by that column.
  • The detail pane shows the type, range or enum values, the description, and the default, current, User and VR values. The value editor depends on the type: an ON/Off switch for booleans, a dropdown for enums, and a text box for everything else. "Save to" can target User.cfg, VR.cfg, or both. It also has Apply & Save, Fill with default, and Remove override.
  • Changes save straight to disk. Booleans and enums save when clicked; text values save on Enter or Apply.
  • System, Light and Dark themes. The choice is stored in HKCU\Software\BmsConfig. The title bar turns dark in dark mode.
  • Full Screen button, plus shortcuts: F11 for full screen, F5 to reload, Ctrl+O to open a folder, Ctrl+F to search.

Tests / CI

  • tests/BmsConfig.Tests has 46 xUnit tests. The project targets net8 and links the Core source files directly, so the tests run on any OS.
  • .github/workflows/build.yml runs the tests and builds Config.exe on windows-latest, and uploads the exe as an artifact.

Testing

  • Unit tests pass on Linux and on Windows CI.
  • Windows CI build succeeds (run 1); Config.exe is available as an artifact.
  • Manual check of the UI on Windows by the repo owner.
  • Wine and Win11-ARM64 have not been tested.

Follow-ups

  • Replace the placeholder Config.ico and Logo.png with the real artwork.

Generated by Claude Code

- Core: line-preserving cfg parser/editor, value conversion and validation
  (ranges, enums, hex ints, fancy quotes, feature-flag regexes), 3-file
  merge with last-writer-wins, Launcher cut-line handling, install discovery
- UI: master/detail window with search, category and modified filters,
  VR view toggle, System/Light/Dark themes, full screen, auto-save
- Unit tests (net8, links Core sources) and a Windows CI build

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KaEsnLMDyw72GZ8a6ZxAGq
@arithex
arithex merged commit 314738c into main Oct 29, 2026
2 checks passed
@arithex
arithex deleted the claude/affectionate-goodall-gn2lqa branch October 29, 2026 03:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants