CLI Reference
The LMESH CLI connects your local operating system shell (POSIX PTY / ConPTY) to the relay server via secure WebSockets. Below is the complete syntax, flag specifications, and practical usage examples for all subcommands.
lmesh-clinpm i -g lmesh-cliView on npmCommand Syntax
All LMESH commands can be invoked using either lmesh (when installed globally) or npx lmesh-cli:
lmesh <command> [options]Authenticate CLI identity via GitHub Device Authorization Flow.
Spawn a local pseudo-terminal and stream live over WebSockets.
Display active authenticated GitHub profile and credentials status.
Revoke and clear locally stored credentials from disk.
lmesh login
authInitiates GitHub OAuth Device Authorization. The CLI prints a one-time 8-character user code and automatically opens GitHub's verification page. Once authorized, an encrypted JWT is saved to ~/.lmesh/auth.json.
lmesh loginlmesh whoami
utilityInspects your local credentials configuration and outputs the active GitHub username, user ID, and auth status.
lmesh whoamilmesh logout
utilitySafely removes the stored JWT token and user profile from ~/.lmesh/auth.json.
lmesh logoutCommand Flags & Options
Summary of all command-line flags accepted by lmesh share:
| Flag | Alias | Type | Default | Description |
|---|---|---|---|---|
| --port | -p | number | 3001 | Port of the relay WebSocket server. |
| --host | -h | string | localhost | Hostname of the relay WebSocket server. |
| --url | -u | string | none | Direct WebSocket URL override (e.g. wss://relay.example.com). |
| --password | -w | string | none | Passphrase required for collaborators to join the session. |
| --readonly | -r | boolean | false | Start session in read-only broadcast mode (no control requests). |
| --help | -h | boolean | false | Print usage guide and options list to stdout. |
| --version | -V | boolean | false | Display the installed CLI version number. |