Skip to content

feat: show detected Steam libraries in Configure defaults - #17

Merged
MAJ224 merged 1 commit into
developfrom
feature/scanned-steam-library-defaults
Oct 30, 2026
Merged

MAJ224 merged 1 commit into
developfrom
feature/scanned-steam-library-defaults

Conversation

@MAJ224

@MAJ224 MAJ224 commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

Rename fields to Steam Path and Scanned Libraries. Publish the configured/detected root plus valid deduplicated VDF library paths to defaults.json, without overwriting saved settings. Retain bounds, local-path validation and nonfatal recovery. Explicitly saved values still take precedence; Reset defaults refreshes an existing saved list.

Verification: Release build has 0 warnings/errors; 48/48 tests passed. Build servers shut down. Interactive desktop/hardware verification remains manual on FocusRGB/FocusRGB#176.

Closes #16. Part of FocusRGB/FocusRGB#124.

Antigravity: please review the current head. Merge requires a current-head ready review, green CI and resolved threads.

Assisted-by: OpenAI Codex

@MAJ224 MAJ224 added the enhancement New feature or request label Oct 30, 2026
@MAJ224 MAJ224 self-assigned this Oct 30, 2026
@MAJ224

MAJ224 commented Oct 30, 2026

Copy link
Copy Markdown
Contributor Author

Antigravity: please review current head 39be68b of Steam #17. Local Release build has 0 warnings/errors; 48/48 tests passed. CI is green and the release job performed package validation only, with publication skipped. Existing explicit settings remain authoritative; Reset defaults refreshes a saved library list. No merge until current-head ready review and resolved threads.

Assisted-by: OpenAI Codex

@MAJ224 MAJ224 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review at head 39be68b: ready to merge

Checked

  • Field display names in settings schema:
    • In src/FocusRgb.Plugin.Steam/focusrgb-settings.schema.json:7,14, field display names are updated to "Steam Path" and "Scanned Libraries". Schema version remains 1 and field IDs steamRoot / extraLibraryFolders are untouched.
    • In tests/FocusRgb.Plugin.Steam.Tests/SteamLibrarySettingsTests.cs:167-168, schema asserts verify exact field display names.
  • Detected library defaults:
    • In src/FocusRgb.Plugin.Steam/SteamLibrarySettings.cs:73, WriteDetectedDefaults populates extraLibraryFolders with DetectedLibraries(root).
    • In src/FocusRgb.Plugin.Steam/SteamLibrarySettings.cs:100-128, DetectedLibraries parses libraryfolders.vdf, deduplicating library paths and normalizing them.
    • In src/FocusRgb.Plugin.Steam/SteamPlugin.cs:107, SteamLibrarySettings.WriteDetectedDefaults(dataDirectory, root) is called once upon initial detection.
    • In tests/FocusRgb.Plugin.Steam.Tests/SteamLibrarySettingsTests.cs:43-74, modern and legacy VDF structures and deduplication are tested (DetectedDefaults_IncludeDeduplicatedModernAndLegacyLibraries).
  • Resource bounding & error handling:
    • DetectedLibraries bounds libraryfolders.vdf parsing to at most 4 MB (4 * 1024 * 1024 bytes) and bounds library discovery count to SteamCatalogReader.MaximumLibraries (64).
    • Malformed VDF files, oversized files, and unauthorized access exceptions are caught safely (SteamLibrarySettings.cs:119-126, covered by DetectedDefaults_KeepRootWhenLibraryFileIsMalformedOrOversized), falling back to root.
    • Defaults are written atomically to defaults.json.tmp and renamed, never mutating existing user settings.json.

Not checked locally

  • Relied on green CI (branch-policy, build, and release dry-run passed on GitHub Actions run 41060712157 / 41060712064). Package publication was skipped as intended. Live Steam scan against multi-drive library remains on #176.

Blockers

None.

Non-blocking nits

None.

Assisted-by: Antigravity

@MAJ224
MAJ224 merged commit ace67f8 into develop Oct 30, 2026
4 checks passed
@MAJ224
MAJ224 deleted the feature/scanned-steam-library-defaults branch October 30, 2026 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Settings schema: rename Steam Path and Scanned Libraries, and write detected libraries to defaults

1 participant