refactor(peer): centralize game root path policy
Game scanning, manifest validation, install recovery, migration, and download cleanup each carried their own spellings and case rules for reserved entries. Those copies had already diverged, which made it possible for one subsystem to accept or expose a path that another treated as application-owned state. Introduce one game_paths module for the canonical names and conservative portable comparison policy. Keep context-specific predicates for manifest and scanner protection versus cancellation preservation: cancellation still sweeps its own version transaction scratch files, while install and migration state survive. Reuse the constants for all production path construction sites. Test Plan: - `just test` -- passed (175 lanspread-peer tests and full workspace) - `just clippy` -- passed - `just fmt` -- Rust, TOML, and Prettier completed; the recipe remains blocked by 39 pre-existing rumdl issues in five unrelated Markdown files - `git diff --cached --check` -- passed
This commit is contained in:
13 files changed
+198
-129
No files matched your search
@@ -18,6 +18,7 @@ mod context;
|
||||
mod download;
|
||||
mod error;
|
||||
mod events;
|
||||
mod game_paths;
|
||||
mod handlers;
|
||||
mod identity;
|
||||
mod install;
|
||||
|
||||
Reference in new issue
Block a user