https://gitlab.synchro.net/main/sbbs/-/commit/bebebc90a9cbfc35002b3079
Modified Files:
docs/superpowers/specs/2026-08-02-syncretro-save-restore-design.md exec/load/syncretro_lobby.js exec/tests/syncretro_config_test.js src/doors/syncretro/DESIGN.md README.md syncretro_door.c xtrn/syncarcade/README.md xtrn/syncivision/README.md xtrn/syncnes/README.md
Log Message:
syncretro: document suspend/resume and fix its test data-dir leak
Task 6 of the save/restore plan: player-facing docs for all three
console packages, -state documented beside -home in the door's own
README and DESIGN.md, and four corrections earlier tasks surfaced.
- Drop the "-state auto derives the key" promise from the door's
usage text and the design spec's permission table. It cannot be
derived where -state is parsed: sr_door_state_key() is populated
during argv parsing, before sr_config_apply(), rc_core_open() and
option resolution give it anything to hash. A bare "-state auto"
still works exactly like any other key -- it just names the file
literally "auto" rather than deriving anything.
- Give syncretro_lobby_init() a spec.data_dir override (default
system.data_dir), and route every data_dir-derived path in
syncretro_lobby.js (the core-hash cache, the shared/private -home,
the plays log) through it. exec/tests/syncretro_config_test.js now
points it at system.temp_dir, so a test run -- pass or fail -- can
no longer write into the live install's data/. This replaces
cleanup calls that only ran on the success path, which is exactly
the run a regression test needs to survive.
- Fix the cabinet toggle's documented hotkey: the design spec's
mockup still said "(P to switch)", but P is the lobby's existing
Prev-page hotkey, so the shipped code correctly binds C instead.
- Reword the cabinet lines so both read as a rule rather than a
status: "No saved games." parses on a fast read as "none saved
yet" rather than "you cannot save here", which costs a player the
game they believed was saved.
Verified: all 11 ctest suites pass; all five JS suites (syncretro_state_test.js, syncretro_config_test.js, and the three test_shipped_ini.js files) report 0 failures. Confirmed by directory
listing that a full test run leaves /sbbs/data/syncretro/ unchanged.
Confirmed by grep that every -home/save_dir use in main.c and
syncretro_state.c is a destination (NULL-checked, formatted into a
path) and never a comparison or pattern match against the path
itself.
Co-Authored-By: Claude Opus 5 (1M context) <
noreply@anthropic.com>
---
þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net