it2 session autorespond
Monitor and automatically respond to session prompts
Synopsis
it2 session autorespond [<session-id>] [flags]
Description
Monitor a session and automatically respond to prompts and patterns.
This command watches session content and automatically:
- Sends Enter when prompts are detected
- Responds to custom patterns
- Can execute custom commands based on patterns
Examples:
Monitor current session with default patterns
it2 session autorespond
Monitor specific session
it2 session autorespond ABC-123-DEF
Add custom patterns
it2 session autorespond --pattern "Continue?" --pattern "Proceed?"
Load patterns from config file
it2 session autorespond --config ~/.it2-patterns.yaml
Options
-
--config - Path to YAML config file with patterns and responses
-
--interval(default 3) - Monitoring interval in seconds
-
--pattern - Custom patterns to match (can be specified multiple times)
-
--verbose - Show detailed monitoring information
Options inherited from parent commands
-
--format(default "text") - Output format (text, json, yaml) - affects how command results are displayed
-
--timeout - Timeout for API operations - how long to wait for iTerm2 to respond
-
--url - WebSocket URL for iTerm2 API - typically ws://localhost:1912 for local iTerm2
See Also
- it2 session - Manage iTerm2 sessions