Versions in this module Expand all Collapse all v0 v0.2.1 Oct 22, 2026 v0.2.0 Oct 20, 2026 Changes in this version type Screen + Title string type Session + func (s *Session) State(ctx context.Context) (SessionState, error) + func (s *Session) WaitForEnd(ctx context.Context, options ...WaitOption) (SessionState, error) + type SessionState struct + Ended bool + Error string type TerminalEventType + const EventUnsupported type WaitError + Dump string + DumpPath string v0.0.1 Sep 11, 2026 Changes in this version + func IsTimeout(err error) bool + type Attributes uint16 + const Blink + const Bold + const Conceal + const Reverse + const Underline + func (attributes Attributes) Has(requested Attributes) bool + type Cell struct + Attributes Attributes + Background Color + Foreground Color + Text string + Width int + type Color int16 + const Black + const Blue + const Cyan + const DefaultColor + const Green + const Magenta + const Red + const White + const Yellow + type Connection struct + func (c *Connection) Close(ctx context.Context) error + func (c *Connection) ID() uint64 + func (c *Connection) OpenSession(ctx context.Context, options ...SessionOption) (*Session, error) + type ConnectionConfig interface + type Cursor struct + Column int + Row int + Visible bool + type Driver struct + func Launch(ctx context.Context, options ...LaunchOption) (*Driver, error) + func (c *Driver) Close() error + func (c *Driver) Connect(ctx context.Context, config ConnectionConfig) (*Connection, error) + type EventSubscription struct + Events <-chan TerminalEvent + func (s *EventSubscription) Close(ctx context.Context) error + type IdleOption func(*idleConfig) error + func IdleFor(duration time.Duration) IdleOption + func IdleTimeout(timeout time.Duration) IdleOption + type Key string + const ArrowDown + const ArrowLeft + const ArrowRight + const ArrowUp + const Backspace + const Delete + const End + const Enter + const Escape + const F1 + const F10 + const F11 + const F12 + const F2 + const F3 + const F4 + const F5 + const F6 + const F7 + const F8 + const F9 + const Home + const Insert + const PageDown + const PageUp + const Tab + type LaunchOption func(*launchConfig) error + func WithDefaultTimeout(timeout time.Duration) LaunchOption + func WithDriverArgs(arguments ...string) LaunchOption + func WithDriverEnvironment(environment ...string) LaunchOption + func WithDriverPath(path string) LaunchOption + func WithDriverStderr(stderr io.Writer) LaunchOption + type Matcher interface + func All(matchers ...Matcher) Matcher + func Any(matchers ...Matcher) Matcher + func Contains(text string) Matcher + func CursorAt(column, row int) Matcher + func LineEquals(row int, text string) Matcher + func Not(child Matcher) Matcher + type Modifier string + const Alt + const Control + const Meta + const Shift + type Position struct + Column int + Row int + type RPCError struct + Code int + Data json.RawMessage + Message string + func (e *RPCError) Error() string + type SSH struct + Address string + HostKeyFingerprint string + InsecureSkipHostKeyCheck bool + KnownHostsFile string + Password string + PrivateKey string + PrivateKeyPassphrase string + Timeout time.Duration + Username string + type Screen struct + Cells []Cell + Content string + Cursor Cursor + Height int + Revision uint64 + Width int + func (s Screen) CellAt(column, row int) (Cell, bool) + func (s Screen) Contains(text string) bool + func (s Screen) Find(text string) (Position, bool) + func (s Screen) Line(row int) string + func (s Screen) Text() string + type ScreenSubscription struct + Screens <-chan Screen + func (s *ScreenSubscription) Close(ctx context.Context) error + type Session struct + func (s *Session) Close(ctx context.Context) error + func (s *Session) ID() uint64 + func (s *Session) Press(ctx context.Context, key Key, modifiers ...Modifier) error + func (s *Session) Resize(ctx context.Context, width, height int) error + func (s *Session) Screen(ctx context.Context) (Screen, error) + func (s *Session) Send(ctx context.Context, data []byte) error + func (s *Session) Subscribe(ctx context.Context) (*ScreenSubscription, error) + func (s *Session) SubscribeEvents(ctx context.Context) (*EventSubscription, error) + func (s *Session) Type(ctx context.Context, text string) error + func (s *Session) WaitFor(ctx context.Context, matcher Matcher, options ...WaitOption) (Screen, error) + func (s *Session) WaitForIdle(ctx context.Context, options ...IdleOption) (Screen, error) + func (s *Session) WaitForText(ctx context.Context, text string, options ...WaitOption) (Screen, error) + func (s *Session) WaitForTextGone(ctx context.Context, text string, options ...WaitOption) (Screen, error) + type SessionOption func(*sessionConfig) error + func WithAnswerback(answerback string) SessionOption + func WithSize(width, height int) SessionOption + func WithTerminal(profile TerminalProfile) SessionOption + type Telnet struct + Address string + Timeout time.Duration + type TerminalEvent struct + Data string + Sequence uint64 + Type TerminalEventType + type TerminalEventType string + const EventBell + const EventEnquiry + type TerminalProfile string + const VT220 + const XTerm256Color + type WaitError struct + Cause error + Expected string + Kind string + LastScreen Screen + func (e *WaitError) Error() string + func (e *WaitError) Unwrap() error + type WaitOption func(*waitConfig) error + func StableFor(duration time.Duration) WaitOption + func WaitTimeout(timeout time.Duration) WaitOption