# lanspread-peer-cli Scriptable peer harness for automated LAN-spread tests. The binary starts the core peer runtime without the Tauri GUI, reads one JSON command per stdin line, and writes JSONL events, results, and errors to stdout. ## Running ```bash just peer-cli-build just peer-cli-image just peer-cli-run alpha ``` Useful flags: - `--games-dir PATH` stores local archives and installs. - `--state-dir PATH` stores the generated peer identity. - `--fixture GAME_ID` seeds a tiny archive that the fixture unpacker can install. - `--no-mdns` disables mDNS so tests can use explicit `connect` commands. ## Commands Every command is a JSON object with `cmd` or `command`; `id` is optional and is echoed back on the result or error line. ```json {"id":"s1","cmd":"status"} {"id":"p1","cmd":"wait-peers","count":1,"timeout_ms":5000} {"id":"c1","cmd":"connect","addr":"127.0.0.1:34567"} {"id":"g1","cmd":"list-games"} {"id":"d1","cmd":"download","game_id":"fixture-one","install":true} {"id":"i1","cmd":"install","game_id":"fixture-one"} {"id":"u1","cmd":"uninstall","game_id":"fixture-one"} {"id":"q1","cmd":"shutdown"} ```