libtmux Reference MCP Search
On this page

Go API reference

2620 symbols, extracted from source. Every type name in a signature links to its own entry; every cross-reference in a doc comment resolves against the same table.

By module 5 modules

  • tmux 488
  • tmuxq 6
  • tmuxtest 22
  • workspace 8
  • Types 21
Server 2 types
Session 4 types
Window 9 types
WindowID 1 members

WindowID is tmux's stable window identifier, including its @ sigil. It does not distinguish linked-session views; the zero value is not a usable target.

Window 155 members

Window is one materialized (session, index, window) winlink record. It is normally returned by Server.Snapshot , Server.Window , or Window.Refresh . A zero Window is not a usable tmux target.

WindowSize 2 members

WindowSize is a typed value for the "window-size" tmux option. Its zero value is invalid.

WindowOptionValues 74 members

WindowOptionValues is an immutable materialized view of known window option values; its zero value is empty and it does not refresh. Obtain it with Window.Options or GlobalWindowScope.Options . OptionValue.Get reports presence and OptionValue.Origin reports inheritance. Use Window.RawOption or GlobalWindowScope.RawOption for caller-named or undecoded values.

GlobalWindowScope 86 members

GlobalWindowScope is an immutable handle for global window options and hooks. Its zero value is invalid because it contains a zero Server .

NewWindowDirection 0 members

NewWindowDirection selects placement relative to the target winlink on tmux 3.2a or later. Its zero value lets Session.NewWindow with nil Index use the next free index, while Window.NewWindow keeps the receiver's exact occupied target.

RotateWindowDirection 0 members

RotateWindowDirection selects rotate-window's direction on tmux 3.2a or later. Its zero value uses tmux's default rotation.

WindowResizeDirection 0 members

WindowResizeDirection selects one directional resize operation on tmux 3.2a or later. Its zero value selects no directional adjustment.

Window 13 members

Window is one window in a workspace.

Pane 14 types
PaneDirection 0 members

PaneDirection selects where a tiled pane is created or moved on tmux 3.2a or later. Its zero value places the pane below the target.

PaneID 1 members

PaneID is tmux's stable pane identifier, including its % sigil. It does not distinguish linked-session views; the zero value is not a usable target.

Pane 162 members

Pane is one materialized pane record within a specific winlink. It is normally returned by Server.Snapshot , Server.Pane , or Pane.Refresh . A zero Pane is not a usable tmux target.

PaneBorderIndicators 2 members

PaneBorderIndicators is a typed value for the "pane-border-indicators" tmux option. Its zero value is invalid.

PaneBorderLines 2 members

PaneBorderLines is a typed value for the "pane-border-lines" tmux option. Its zero value is invalid.

PaneBorderStatus 2 members

PaneBorderStatus is a typed value for the "pane-border-status" tmux option. Its zero value is invalid.

PaneScrollbars 2 members

PaneScrollbars is a typed value for the "pane-scrollbars" tmux option. Its zero value is invalid.

PaneScrollbarsPosition 2 members

PaneScrollbarsPosition is a typed value for the "pane-scrollbars-position" tmux option. Its zero value is invalid.

PaneOptionValues 19 members

PaneOptionValues is an immutable materialized view of known pane option values; its zero value is empty and it does not refresh. Obtain it with Pane.Options . OptionValue.Get reports presence and OptionValue.Origin reports inheritance. Use Pane.RawOption for caller-named or undecoded values.

PaneResizeDirection 0 members

PaneResizeDirection selects a directional Pane.Resize . Its zero value selects no directional adjustment.

PaneSize 0 members

PaneSize is an opaque absolute cell count or percentage for Pane.Resize . Its zero value omits the dimension. [PaneCells](0) and [PanePercent](0) are explicit sizes, not zero PaneSize values.

SwapPaneDirection 0 members

SwapPaneDirection selects an adjacent pane for swap-pane on tmux 3.2a or later. Its zero value selects no adjacent pane.

PaneSelectDirection 0 members

PaneSelectDirection selects a pane relative to the command target on tmux 3.2a or later. Its zero value selects no relative direction.

Pane 11 members

Pane is one pane in a window. YAML accepts either a bare command string or a mapping, so "echo hello" and {shell_command: echo hello} are equivalent.

Client 3 types
Hooks 4 types
Options 21 types
AllowPassthrough 2 members

AllowPassthrough is a typed value for the "allow-passthrough" tmux option. Its zero value is invalid.

CopyModeLineNumbers 2 members

CopyModeLineNumbers is a typed value for the "copy-mode-line-numbers" tmux option. Its zero value is invalid.

DestroyUnattached 2 members

DestroyUnattached is a typed value for the "destroy-unattached" tmux option. Its zero value is invalid.

DetachOnDestroy 2 members

DetachOnDestroy is a typed value for the "detach-on-destroy" tmux option. Its zero value is invalid.

ExtendedKeys 2 members

ExtendedKeys is a typed value for the "extended-keys" tmux option. Its zero value is invalid.

GetClipboard 2 members

GetClipboard is a typed value for the "get-clipboard" tmux option. Its zero value is invalid.

MenuBorderLines 2 members

MenuBorderLines is a typed value for the "menu-border-lines" tmux option. Its zero value is invalid.

MessageLine 2 members

MessageLine is a typed value for the "message-line" tmux option. Its zero value is invalid.

ModeKeys 2 members

ModeKeys is a typed value for the "mode-keys" tmux option. Its zero value is invalid.

PopupBorderLines 2 members

PopupBorderLines is a typed value for the "popup-border-lines" tmux option. Its zero value is invalid.

RemainOnExit 2 members

RemainOnExit is a typed value for the "remain-on-exit" tmux option. Its zero value is invalid.

SetClipboard 2 members

SetClipboard is a typed value for the "set-clipboard" tmux option. Its zero value is invalid.

Status 2 members

Status is a typed value for the "status" tmux option. Its zero value is invalid.

StatusJustify 2 members

StatusJustify is a typed value for the "status-justify" tmux option. Its zero value is invalid.

StatusKeys 2 members

StatusKeys is a typed value for the "status-keys" tmux option. Its zero value is invalid.

StatusPosition 2 members

StatusPosition is a typed value for the "status-position" tmux option. Its zero value is invalid.

VisualActivity 2 members

VisualActivity is a typed value for the "visual-activity" tmux option. Its zero value is invalid.

VisualBell 2 members

VisualBell is a typed value for the "visual-bell" tmux option. Its zero value is invalid.

VisualSilence 2 members

VisualSilence is a typed value for the "visual-silence" tmux option. Its zero value is invalid.

OptionOrigin 1 members

OptionOrigin identifies where a present option value was resolved. The declared values form the complete set of valid origins.

OptionValue 2 members

OptionValue preserves option presence and resolution origin. Its zero value is absent. Copies of reference-bearing T values are shallow.

Keys and bindings 1 type
Environment 1 type
Terminal capabilities 7 types
Versions 1 type
Version 7 members

Version is a parsed tmux version that preserves its original token. Obtain a value with ParseVersion , Server.Version , or Snapshot.Version . Its zero value has no feature level and is useful only as an absent version. Parsed OpenBSD base-system tokens also have no feature level until Server.Version probes the configured binary's commands.

Commands 4 types
Control mode 4 types
Formats 2 types
Queries 7 types
SessionFilter 15 members

SessionFilter matches materialized Session values without tmux I/O. Its zero value matches every non-nil candidate. Criteria are ANDed; AnyOf adds an OR requirement and Not excludes. Field and relation criteria correspond to Session.ID , Session.Name , Session.Attached , Session.Windows , and Session.Panes . SessionFilter.Validate and methods that consume the filter reject invalid criteria with ErrInvalidFilter.

WindowFilter 23 members

WindowFilter matches materialized Window values without tmux I/O. Its zero value matches every non-nil candidate. Criteria are ANDed; AnyOf adds an OR requirement and Not excludes. Field and relation criteria correspond to Window.SessionID , Window.ID , Window.Index , Window.Name , Window.Active , Window.Session , and Window.Panes . WindowFilter.Validate and methods that consume the filter reject invalid criteria with ErrInvalidFilter.

PaneFilter 35 members

PaneFilter matches materialized Pane values without tmux I/O. Its zero value matches every non-nil candidate. Criteria are ANDed; AnyOf adds an OR requirement and Not excludes. Field and relation criteria correspond to Pane.SessionID , Pane.WindowID , Pane.ID , Pane.WindowIndex , Pane.Index , Pane.CurrentCommand , Pane.Active , Pane.Title , Pane.Session , and Pane.Window . PaneFilter.Validate and methods that consume the filter reject invalid criteria with ErrInvalidFilter.

ClientFilter 14 members

ClientFilter matches materialized Client values without tmux I/O. Its zero value matches every non-nil candidate. Criteria are ANDed; AnyOf adds an OR requirement and Not excludes. Field and relation criteria correspond to Client.Name , Client.ReadOnly , Client.AttachedSession , Client.AttachedWindow , and Client.AttachedPane . ClientFilter.Validate and methods that consume the filter reject invalid criteria with ErrInvalidFilter.

WindowRel 5 members

WindowRel applies quantifiers to a materialized Window relation; its zero value is invalid. Some is existential, Every is universal and vacuously true for an empty relation, and None excludes; enabled quantifiers are conjunctive.

PaneRel 5 members

PaneRel applies quantifiers to a materialized Pane relation; its zero value is invalid. Some is existential, Every is universal and vacuously true for an empty relation, and None excludes; enabled quantifiers are conjunctive.

TmuxFilter 0 members

TmuxFilter is a raw tmux -f format expression. It is distinct from the generated local filter structs and is evaluated only by tmux. A nil filter omits -f; a nonnil empty filter sends an explicit empty expression.

Snapshots 2 types
Workspaces 6 types
Workspaces — Plans 3 types
Requests 28 types
DisplayMessageRequest 9 members

DisplayMessageRequest configures display-message options shared by server, window, and pane scope. A zero request displays tmux's default message and returns nil. Print returns an owned stdout slice instead of displaying only to a client status line. Nil pointer fields omit their flags while pointers to empty values are explicit; a zero TargetClient omits its flag.

SendKeysRequest 11 members

SendKeysRequest configures tmux key input. Pointer values are copied before I/O and must not be mutated concurrently.

SendKeySequenceRequest 2 members

SendKeySequenceRequest configures ordered pane key delivery. Keys must contain at least one nonempty operand. SendKeySequence copies Keys before I/O; callers must not mutate it concurrently with the call.

ClearHistoryRequest 1 members

ClearHistoryRequest configures pane history clearing. Its zero value clears scrollback without requesting hyperlink cleanup.

CopyModeRequest 6 members

CopyModeRequest configures tmux copy mode. Its zero value enters copy mode on the receiver without scrolling. Fields may be combined. tmux resolves the receiver and optional SourcePane before processing Cancel, so a stale target can prevent reset. After resolution, Cancel takes precedence over other actions, though SourcePane validation and the PageDown version probe still occur first.

ChooseTreeRequest 7 members

ChooseTreeRequest configures the interactive session and window chooser. Its zero value uses tmux defaults. Format and Filter are copied before execution and must not be mutated concurrently.

DisplayPopupRequest 18 members

DisplayPopupRequest configures a popup overlay. Pointer and map values are copied before I/O and must not be mutated concurrently. Pointer fields distinguish omission from an explicit empty value, with the Command and StartDirectory behavior documented on those fields.

PasteBufferRequest 6 members

PasteBufferRequest configures one tmux paste-buffer operation. Its zero value pastes the top buffer, replaces linefeeds with tmux's default carriage-return separator, and uses the version's default control-character handling. Pointer values are copied before I/O and must not be mutated concurrently.

SetPlanOptionRequest 7 members

SetPlanOptionRequest names one tmux option write for Plan.SetOption . Its zero value is invalid, because Name is required.

PromptHistoryRequest 1 members

PromptHistoryRequest selects one prompt-history class. A zero request selects every class.

SetBufferRequest 3 members

SetBufferRequest configures storing data in a tmux paste buffer. Its zero value writes an empty most-recent buffer; nil Name selects that buffer while a pointer to an empty name is explicit.

SaveBufferRequest 3 members

SaveBufferRequest configures writing a tmux paste buffer to a file. Its zero value is invalid because Path is required; nil Name selects the most-recent buffer and a pointer to an empty name is explicit.

LoadBufferRequest 2 members

LoadBufferRequest configures loading a file into a tmux paste buffer. Its zero value is invalid because Path is required; nil Name lets tmux allocate a buffer and a pointer to an empty name is explicit.

ListBuffersRequest 2 members

ListBuffersRequest configures tmux's live paste-buffer listing. Its zero value requests tmux's default output; nil Format and Filter omit their flags, whereas pointers to empty strings are explicit expressions.

RunShellRequest 8 members

RunShellRequest configures a command executed by tmux's run-shell command. Its zero value is invalid because Command is required. Pointer fields distinguish omitted flags from explicit empty arguments; RunShell copies Delay, StartDirectory, and Args before invoking tmux.

WaitForRequest 2 members

WaitForRequest configures a wait, signal, lock, or unlock operation. Its zero value waits on the required nonempty Channel.

IfShellRequest 5 members

IfShellRequest configures conditional execution of a tmux command. Its zero value is invalid because ShellCommand and ThenCommand are required; nil ElseCommand omits the failure branch while a pointer to an empty string is explicit.

SourceFileRequest 4 members

SourceFileRequest configures loading or parsing a tmux configuration file. Its zero value is invalid because Path is required; SourceFile expands only the current user's ~ forms and copies no caller-owned mutable input.

ConfirmBeforeRequest 5 members

ConfirmBeforeRequest configures a background tmux confirmation prompt. Its zero value is invalid because Command is required. Nil pointer fields omit their flags while explicit empty strings are passed to tmux; ConfirmKey must be one printable ASCII character.

CommandPromptRequest 13 members

CommandPromptRequest configures a background tmux command prompt. Its zero value is invalid because Template is required; nil pointer fields omit flags while explicit empty values are passed to tmux.

DisplayMenuRequest 13 members

DisplayMenuRequest configures one tmux popup menu. Position and style strings retain tmux's format and symbolic-position languages verbatim. Its zero value is invalid because Items is required. All pointer fields omit their flags when nil and retain explicit empty strings; DisplayMenu copies Items before calling tmux. TargetPane and TargetClient are independent but must be stable identities when present.

BindKeyRequest 5 members

BindKeyRequest configures one tmux key binding. Its zero value is invalid because Key is required; nil KeyTable and Note omit their flags while pointers to empty strings are explicit.

UnbindKeyRequest 4 members

UnbindKeyRequest selects one key or an entire key table to unbind. Exactly one of Key and AllKeys must be set.

ListKeysRequest 2 members

ListKeysRequest configures raw key-binding output. Its zero value selects tmux's default table and format; nil fields omit flags while explicit empty pointers are passed to tmux.

ListCommandsRequest 1 members

ListCommandsRequest optionally limits output to one tmux command or alias. Nil CommandName lists all commands; a pointer to an empty name is explicit.

ShowMessagesRequest 3 members

ShowMessagesRequest selects the target and server information to print. Terminals and Jobs are independent and may both be enabled.

SelectLayoutRequest 4 members

SelectLayoutRequest selects one layout operation. Its zero value reapplies the last preset layout. Layout, Spread, Next, and Previous are mutually exclusive and are validated before execution; an empty Layout is omitted rather than passed explicitly. The request contains no retained caller-owned storage and is supported on tmux 3.2a or later.

RespawnRequest 4 members

RespawnRequest configures restarting a window's or pane's process on tmux 3.2a or later. Its zero value reuses the stored command and directory and requires the target process to be inactive. Nil pointer fields omit their options; nonnil pointers are explicit, including empty strings. There are no mutually exclusive fields. Arguments and environment entries are validated before execution.

Requests — Server 1 type
Requests — Session 4 types
Requests — Window 11 types
KillWindowRequest 2 members

KillWindowRequest selects a window for Session.KillWindow on tmux 3.2a or later. A zero request kills the receiver session's current window, and Index is scoped to that session. Target is unrestricted tmux target syntax and may select a window in another session. Target and Index are mutually exclusive and are checked before execution. Pointer values are read during the call and are not retained; callers must not mutate them concurrently. A nil pointer omits its selector, while a nonnil pointer is explicit even when Target points to an empty string.

FindWindowRequest 6 members

FindWindowRequest configures the interactive window search chooser. Match is a tmux search operand, not a shell command. The zero value searches with an empty glob using tmux's default name, title, and visible-content scopes.

SelectWindowRequest 2 members

SelectWindowRequest selects one winlink in a Session on tmux 3.2a or later. Its zero value is invalid: exactly one of WindowID and Index is required. That mutual exclusion, stable-ID syntax, and a nonnegative Index are validated before execution. Index is read during the call and is not retained; nil omits it, a nonnil pointer is explicit, and callers must not mutate it concurrently.

NewWindowRequest 9 members

NewWindowRequest configures window creation on tmux 3.2a or later. Its zero value uses inherited defaults; placement behavior depends on the receiver. Session.NewWindow uses tmux's next free index. Window.NewWindow instead targets the receiver's occupied index and normally returns a command error; KillExisting may replace it. Window.NewWindow rejects Index. SelectExisting may run name-expansion probes before creation.

LinkWindowRequest 6 members

LinkWindowRequest configures linking a window into another session on tmux 3.2a or later. Its zero value is invalid because TargetSession is required. Nil TargetIndex asks tmux for a destination index; a nonnil value is explicit and must be nonnegative. After and Before are mutually exclusive and are rejected before execution. TargetIndex is read during the call and is not retained; callers must not mutate it concurrently.

UnlinkWindowRequest 1 members

UnlinkWindowRequest configures unlinking one exact winlink on tmux 3.2a or later. Its zero value removes the link only when the stable window has another link. The request contains no retained caller-owned storage and has no invalid field combinations.

MoveWindowRequest 7 members

MoveWindowRequest configures moving one exact winlink on tmux 3.2a or later. Its zero value moves the receiver within its current session to a tmux-chosen index and lets the moved winlink become current. Nil TargetIndex asks tmux for that index; a nonnil value is explicit and must be nonnegative. After and Before are mutually exclusive. Renumber is a standalone mode mutually exclusive with TargetIndex, After, Before, NoSelect, and KillTarget. Invalid combinations are rejected before execution. TargetIndex is read during the call and is not retained; callers must not mutate it concurrently.

SwapWindowRequest 2 members

SwapWindowRequest configures swapping the receiver with one exact winlink on tmux 3.2a or later. Its zero value is invalid because Target must be a complete Window handle. The endpoints must be proven to share a daemon through connection state or the same nonempty SocketPath; matching socket names alone are insufficient. Validation completes before execution.

WindowSelectPaneRequest 3 members

WindowSelectPaneRequest selects either one exact pane or one relative pane. Its zero value is invalid: exactly one of Target and Direction is required. Target must be a complete pane handle in the receiver's exact winlink and must be proven to share a daemon through connection state or the same nonempty SocketPath; matching socket names alone are insufficient. Invalid values are rejected before execution.

RotateWindowRequest 2 members

RotateWindowRequest configures rotate-window. Its zero value uses tmux's default rotation; enum validation happens before execution.

ResizeWindowRequest 6 members

ResizeWindowRequest selects one directional, manual, expand, or shrink operation. Height and Width may be set together. A zero request asks tmux to reapply the current manual size. Direction requires a positive Adjustment; that pair, dimensions, Expand, and Shrink are mutually exclusive and are validated before execution. Zero Adjustment, Height, and Width omit their modes; nonzero values must be positive. The request is supported on tmux 3.2a or later.

Requests — Pane 13 types
PaneDisplayMessageRequest 1 members

PaneDisplayMessageRequest adds the pane-only update behavior to the common display-message options.

CapturePaneRequest 14 members

CapturePaneRequest configures pane capture. Its zero value captures the visible screen with tmux's default text handling. Version-gated flags follow UnsupportedPolicy . CaptureBoundary selects the start of history for Start and the end of the visible pane for End.

NewPaneRequest 15 members

NewPaneRequest configures a floating pane and requires tmux 3.7 or later. Its zero value creates a detached floating pane with tmux's default size, position, styles, and command. Nil pointer fields omit their options; nonnil pointers are explicit, including empty style or message strings. Width and Height must be nonnegative. Empty and Command are mutually exclusive. Unsupported tmux versions return VersionTooLowError rather than omitting fields.

SplitPaneRequest 15 members

SplitPaneRequest configures tiled pane creation on tmux 3.2a or later. Its zero value creates a detached pane below the exact target with tmux's default size and command. Nil pointer fields omit their options; nonnil pointers are explicit, including empty style or message strings. Size and Percentage are mutually exclusive. Invalid values are rejected before tmux is mutated.

ResizePaneRequest 7 members

ResizePaneRequest selects one resize mode. Direction with Adjustment, dimensions, Zoom, Mouse, and TrimBelow are mutually exclusive modes; Height and Width may be set together. Its zero value sends a bare tmux resize-pane command rather than selecting a mode. When Direction is PaneResizeDirectionNone , Adjustment must be zero.

DisplayPanesRequest 2 members

DisplayPanesRequest configures pane-number display for tmux's current client and does not inherit the Pane target. Duration is read during the call, not retained, and must not be mutated concurrently.

PipePaneRequest 4 members

PipePaneRequest configures a pane pipe. Its flags may be combined. Command is copied before I/O and must not be mutated concurrently.

MovePaneRequest 7 members

MovePaneRequest configures move-pane on tmux 3.2a or later. Its zero value is invalid: exactly one complete TargetPane or TargetWindow handle is required. Cross-object handles must be proven to share a daemon through connection state or the same nonempty SocketPath; matching socket names alone are insufficient. Size and Percentage are mutually exclusive. Invalid enum, target, size, and percentage values are rejected before execution.

JoinPaneRequest 7 members

JoinPaneRequest configures join-pane with the same target, cross-daemon, sizing, validation, and pointer-ownership rules as MovePaneRequest .

BreakPaneRequest 2 members

BreakPaneRequest configures break-pane on tmux 3.2a or later. Its zero value moves the receiver to a detached new window with tmux's default name, except for the documented raw-version 3.7 workaround in Pane.BreakPane . Empty Name means omission and is validated before the version probe.

SwapPaneRequest 4 members

SwapPaneRequest configures swapping with an exact or adjacent pane on tmux 3.2a or later. Its zero value is invalid: exactly one complete Target or Direction is required. An explicit Target must differ from the receiver and must be proven to share a daemon through connection state or the same nonempty SocketPath; matching socket names alone are insufficient. Invalid choices are rejected before execution.

PaneSelectRequest 4 members

PaneSelectRequest configures select-pane for one exact receiver. Closed enums prevent conflicting direction, mark, and input flags. Its zero value selects the receiver. Mark rejects every other option. Input rejects Direction and KeepZoom because changing input does not select a pane. These combinations and enum ranges are validated before execution.

LastPaneRequest 2 members

LastPaneRequest configures last-pane on tmux 3.2a or later. Its zero value selects the previously active pane. Input and KeepZoom are mutually exclusive and are validated before execution; an Input mode changes the previous pane's input state without selecting it.

Requests — Client 3 types
Errors 22 types
ColorError 3 members

ColorError reports an unsupported color mode. It matches ErrUnknownColor through errors.Is; callers can recover Mode with errors.As.

CommandError 5 members

CommandError reports a completed failed high-level tmux operation. It matches ErrCommand through errors.Is; callers can recover its fields with errors.As. Generic library operations retain an owned copy of the completed command and output so tmux diagnostics remain available. Operations whose primary payload may contain secrets return an exit-code-only result instead. Callers must treat retained argv and output as potentially sensitive.

ComplexOptionDecodeError 5 members

ComplexOptionDecodeError identifies one malformed sparse-array entry without retaining its raw value.

ControlNotificationError 5 members

ControlNotificationError reports where a control-mode notification failed validation without retaining or disclosing the notification contents. Callers can use errors.Is with Category or errors.As to inspect its secret-safe location metadata. Category is ErrMalformedControlNotification or ErrUnknownControlNotification.

ControlNotificationOverflowError 5 members

ControlNotificationOverflowError reports the backlog limit and the record that would have crossed it. The queued prefix remains available first.

ControlProtocolError 4 members

ControlProtocolError reports a control-stream state violation without retaining or disclosing command output or notification contents. It matches ErrControlProtocol through errors.Is.

EnvironmentNameError 3 members

EnvironmentNameError reports a name that tmux cannot store.

EnvironmentValueError 2 members

EnvironmentValueError reports a value that cannot round-trip through show-environment. It intentionally does not retain or print the environment value.

EnvironmentDecodeError 4 members

EnvironmentDecodeError reports one malformed show-environment record. It never retains the record because environment output may contain secrets.

FormatDecodeError 6 members

FormatDecodeError identifies a malformed escaped tmux format record. It matches ErrMalformedFormatOutput through errors.Is; callers can recover its location fields with errors.As. Library-created errors do not retain decoded record values, which may contain caller data.

FromEnvError 4 members

FromEnvError reports which tmux discovery variable was missing or malformed. It never retains or prints the variable's value.

OptionDecodeError 4 members

OptionDecodeError reports a malformed recognized record without retaining its value. It matches ErrMalformedOptionOutput through errors.Is; callers can recover Record and Reason with errors.As. Record is the zero-based physical output line.

OptionValueError 3 members

OptionValueError reports a rejected typed option value without retaining or rendering that value. It matches ErrInvalidOptionValue and ErrOption.

OptionError 5 members

OptionError reports a completed high-level option or hook failure. It matches ErrOption and a specific option sentinel through errors.Is; callers can recover its fields with errors.As. Library-created errors retain only Result.ExitCode. Error never renders command output because option values and hook commands may be secret; callers may construct exported values with other contents.

CaptureRequestError 5 members

CaptureRequestError reports a CapturePaneRequest field that cannot be represented as a tmux capture-pane argument. It matches ErrInvalidCaptureRequest through errors.Is and is available through errors.As.

PlanError 4 members

PlanError reports a plan this package refused before sending anything to tmux. It matches ErrPlan through errors.Is; callers can recover Step and Reason with errors.As.

VersionQueryError 4 members

VersionQueryError reports an unsuccessful tmux -V probe. It matches ErrVersionQuery through errors.Is; callers can recover its fields with errors.As. Library-created errors retain only the exit code; command arguments and output are omitted, although callers may construct values with other contents.

VersionTooLowError 6 members

VersionTooLowError reports the installed and required tmux feature levels. It matches ErrVersionTooLow through errors.Is; callers can recover its fields with errors.As.

SnapshotDecodeError 7 members

SnapshotDecodeError identifies one malformed decoded list row. It matches ErrMalformedSnapshot through errors.Is; callers can recover its redacted location fields with errors.As.

SnapshotLookupError 5 members

SnapshotLookupError reports the cardinality of an unsuccessful point lookup. It matches ErrSnapshotNotFound or ErrSnapshotAmbiguous through errors.Is; callers can recover its target and count with errors.As.

TargetError 4 members

TargetError reports a malformed stable identifier before command execution. It matches ErrInvalidTarget through errors.Is; callers can recover Object and Target with errors.As.

VersionError 3 members

VersionError reports a tmux version token that cannot be parsed. It matches ErrInvalidVersion through errors.Is; callers can recover Token with errors.As.

Errors — Server 1 type
Constants and enums 24 types
ColorMode 0 members

ColorMode selects a tmux color-capability override for ServerOptions .

CommandResult 5 members

CommandResult contains one completed tmux invocation. Server.Cmd returns it even when tmux exits nonzero. Library operations clone its slices before returning it, so the caller owns Command, Stdout, RawStdout, and Stderr.

TerminalOverrideValueKind 0 members

TerminalOverrideValueKind identifies one closed terminal capability value form.

ConnectionOptions 1 members

ConnectionOptions configures the control-mode lanes owned by a Connection .

ControlCommandResult 6 members

ControlCommandResult is one completed control-mode command frame. A failed tmux command remains result data through Failed; local, protocol, transport, and context failures are returned separately by Connection.Call , ControlClient.Cmd , and ControlClient.Call . All slices are owned by the caller.

SetEnvironmentOptions 2 members

SetEnvironmentOptions controls tmux's value expansion and visibility flags. Its zero value stores Value literally and exposes it to child processes.

SetHooksOptions 1 members

SetHooksOptions controls a bulk hook replacement. Its zero value preserves existing indices before applying the supplied sparse values.

SetHooksResult 2 members

SetHooksResult reports only side effects confirmed before return.

NotificationOptions 2 members

NotificationOptions configures which notifications a stream receives. The zero value retains notifications other than pane output.

ActivityAction 2 members

ActivityAction is a typed value for the "activity-action" tmux option. Its zero value is invalid.

BellAction 2 members

BellAction is a typed value for the "bell-action" tmux option. Its zero value is invalid.

ClockModeStyle 2 members

ClockModeStyle is a typed value for the "clock-mode-style" tmux option. Its zero value is invalid.

CursorStyle 2 members

CursorStyle is a typed value for the "cursor-style" tmux option. Its zero value is invalid.

PromptCommandCursorStyle 2 members

PromptCommandCursorStyle is a typed value for the "prompt-command-cursor-style" tmux option. Its zero value is invalid.

PromptCursorStyle 2 members

PromptCursorStyle is a typed value for the "prompt-cursor-style" tmux option. Its zero value is invalid.

SilenceAction 2 members

SilenceAction is a typed value for the "silence-action" tmux option. Its zero value is invalid.

ControlNotificationKind 1 members

ControlNotificationKind identifies a tmux control-mode notification record. Its zero value is unknown and is not emitted by tmux. ParseControlNotification returns known values for the pinned wire vocabulary and rejects unknown notification records.

SetOptionOptions 3 members

SetOptionOptions controls set-option mutation flags. Its zero value sends no optional mutation flags.

UnsetOptionOptions 2 members

UnsetOptionOptions controls set-option unset behavior. Its zero value unsets only the selected option.

SetArrayResult 2 members

SetArrayResult reports confirmed progress from a typed sparse-array replacement. AppliedIndices is caller-owned and is non-nil whenever mutation was attempted.

PlanResult 3 members

PlanResult reports what running a Plan did, one entry per recorded operation, in the order they were recorded.

OpResult 5 members

OpResult is what one operation in a Plan produced.

WaitForMode 0 members

WaitForMode selects one wait-for operation. The zero value waits until the channel is signaled.

WarningKind 0 members

WarningKind identifies one closed class of nonfatal library warning.

Constants and enums — Server 1 type
ServerOptions 8 members

ServerOptions configures a Server without starting tmux. NewServer snapshots the effective environment, working directory, and executable; callers retain ownership of every supplied value.

Constants and enums — Session 1 type
Constants and enums — Window 1 type
Constants and enums — Pane 3 types
Testing utilities 3 types
Other 10 types
Functions and constants 0 types
ActivityActionAny : ActivityAction
constant [source]
constant [source]
ActivityActionAny

ActivityActionAny selects "any".

ActivityActionCurrent : ActivityAction
constant [source]
constant [source]
ActivityActionCurrent

ActivityActionCurrent selects "current".

ActivityActionNone : ActivityAction
constant [source]
constant [source]
ActivityActionNone

ActivityActionNone selects "none".

ActivityActionOther : ActivityAction
constant [source]
constant [source]
ActivityActionOther

ActivityActionOther selects "other".

AllowPassthroughAll : AllowPassthrough
constant [source]
constant [source]
AllowPassthroughAll

AllowPassthroughAll selects "all".

AllowPassthroughOff : AllowPassthrough
constant [source]
constant [source]
AllowPassthroughOff

AllowPassthroughOff selects "off".

AllowPassthroughOn : AllowPassthrough
constant [source]
constant [source]
AllowPassthroughOn

AllowPassthroughOn selects "on".

BellActionAny : BellAction
constant [source]
constant [source]
BellActionAny

BellActionAny selects "any".

BellActionCurrent : BellAction
constant [source]
constant [source]
BellActionCurrent

BellActionCurrent selects "current".

BellActionNone : BellAction
constant [source]
constant [source]
BellActionNone

BellActionNone selects "none".

BellActionOther : BellAction
constant [source]
constant [source]
BellActionOther

BellActionOther selects "other".

CaptureBoundary : CapturePosition
constant [source]
constant [source]
CaptureBoundary

CaptureBoundary selects the start of history when used as Start and the end of the visible pane when used as End.

ClockModeStyle12 : ClockModeStyle
constant [source]
constant [source]
ClockModeStyle12

ClockModeStyle12 selects "12".

ClockModeStyle12WithSeconds : ClockModeStyle
constant [source]
constant [source]
ClockModeStyle12WithSeconds

ClockModeStyle12WithSeconds selects "12-with-seconds".

ClockModeStyle24 : ClockModeStyle
constant [source]
constant [source]
ClockModeStyle24

ClockModeStyle24 selects "24".

ClockModeStyle24WithSeconds : ClockModeStyle
constant [source]
constant [source]
ClockModeStyle24WithSeconds

ClockModeStyle24WithSeconds selects "24-with-seconds".

Color256 : ColorMode
constant [source]
constant [source]
Color256

Color256 requests tmux's 256-color capability mode.

Color88 : ColorMode
constant [source]
constant [source]
Color88

Color88 requests tmux's 88-color capability mode.

ColorDefault : ColorMode
constant [source]
constant [source]
ColorDefault

ColorDefault preserves tmux's detected color capability.

ControlNotificationClientDetached : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationClientDetached

ControlNotificationClientDetached identifies the %client-detached notification, available since tmux 3.2a. Its wire grammar is %client-detached <client>. ParseControlNotification returns its arguments as client tail.

ControlNotificationClientSessionChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationClientSessionChanged

ControlNotificationClientSessionChanged identifies the %client-session-changed notification, available since tmux 3.2a. Its wire grammar is %client-session-changed <client> <session ID> <session name>. ParseControlNotification returns its arguments as client, session ID, session name tail.

ControlNotificationConfigError : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationConfigError

ControlNotificationConfigError identifies the %config-error notification, available since tmux 3.4. Its wire grammar is %config-error <text>. ParseControlNotification returns its arguments as text tail.

ControlNotificationContinue : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationContinue

ControlNotificationContinue identifies the %continue notification, available since tmux 3.2a. Its wire grammar is %continue <pane ID>. ParseControlNotification returns its arguments as pane ID.

ControlNotificationExit : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationExit

ControlNotificationExit identifies the %exit notification, available since tmux 3.2a. Its wire grammar is %exit or %exit <reason>. ParseControlNotification returns its arguments as reason tail.

ControlNotificationExtendedOutput : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationExtendedOutput

ControlNotificationExtendedOutput identifies the %extended-output notification, available since tmux 3.2a. Its wire grammar is %extended-output <pane ID> <age> { zero or more <reserved argument> } : <data>. ParseControlNotification returns its arguments as the prefix arguments, then zero or more reserved arguments, then the data tail; the prefix arguments are pane ID, age. Its tail may be empty.

ControlNotificationLayoutChange : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationLayoutChange

ControlNotificationLayoutChange identifies the %layout-change notification, available since tmux 3.2a. Its wire grammar is %layout-change <window ID> <layout> <visible layout> <flags>. ParseControlNotification returns its arguments as window ID, layout, visible layout, flags tail. Its tail may be empty.

ControlNotificationMessage : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationMessage

ControlNotificationMessage identifies the %message notification, available since tmux 3.4. Its wire grammar is %message <text>. ParseControlNotification returns its arguments as text tail. Its tail may be empty.

ControlNotificationOutput : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationOutput

ControlNotificationOutput identifies the %output notification, available since tmux 3.2a. Its wire grammar is %output <pane ID> <data>. ParseControlNotification returns its arguments as pane ID, data tail. Its tail may be empty.

ControlNotificationPaneModeChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationPaneModeChanged

ControlNotificationPaneModeChanged identifies the %pane-mode-changed notification, available since tmux 3.2a. Its wire grammar is %pane-mode-changed <pane ID>. ParseControlNotification returns its arguments as pane ID.

ControlNotificationPasteBufferChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationPasteBufferChanged

ControlNotificationPasteBufferChanged identifies the %paste-buffer-changed notification, available since tmux 3.4. Its wire grammar is %paste-buffer-changed <name>. ParseControlNotification returns its arguments as name tail.

ControlNotificationPasteBufferDeleted : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationPasteBufferDeleted

ControlNotificationPasteBufferDeleted identifies the %paste-buffer-deleted notification, available since tmux 3.4. Its wire grammar is %paste-buffer-deleted <name>. ParseControlNotification returns its arguments as name tail.

ControlNotificationPause : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationPause

ControlNotificationPause identifies the %pause notification, available since tmux 3.2a. Its wire grammar is %pause <pane ID>. ParseControlNotification returns its arguments as pane ID.

ControlNotificationSessionChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationSessionChanged

ControlNotificationSessionChanged identifies the %session-changed notification, available since tmux 3.2a. Its wire grammar is %session-changed <session ID> <session name>. ParseControlNotification returns its arguments as session ID, session name tail.

ControlNotificationSessionRenamed : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationSessionRenamed

ControlNotificationSessionRenamed identifies the %session-renamed notification, available since tmux 3.2a. Its wire grammar is %session-renamed <session ID> <session name>. ParseControlNotification returns its arguments as session ID, session name tail.

ControlNotificationSessionsChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationSessionsChanged

ControlNotificationSessionsChanged identifies the %sessions-changed notification, available since tmux 3.2a. Its wire grammar is %sessions-changed. ParseControlNotification returns its arguments as no arguments.

ControlNotificationSessionWindowChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationSessionWindowChanged

ControlNotificationSessionWindowChanged identifies the %session-window-changed notification, available since tmux 3.2a. Its wire grammar is %session-window-changed <session ID> <window ID>. ParseControlNotification returns its arguments as session ID, window ID.

ControlNotificationSubscriptionChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationSubscriptionChanged

ControlNotificationSubscriptionChanged identifies the %subscription-changed notification, available since tmux 3.2a. Its wire grammar is %subscription-changed <name> <session ID> <window ID> <window index> <pane ID> { zero or more <reserved argument> } : <value>. ParseControlNotification returns its arguments as the prefix arguments, then zero or more reserved arguments, then the value tail; the prefix arguments are name, session ID, window ID, window index, pane ID. Its tail may be empty.

ControlNotificationUnlinkedWindowAdd : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationUnlinkedWindowAdd

ControlNotificationUnlinkedWindowAdd identifies the %unlinked-window-add notification, available since tmux 3.2a. Its wire grammar is %unlinked-window-add <window ID>. ParseControlNotification returns its arguments as window ID.

ControlNotificationUnlinkedWindowClose : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationUnlinkedWindowClose

ControlNotificationUnlinkedWindowClose identifies the %unlinked-window-close notification, available since tmux 3.2a. Its wire grammar is %unlinked-window-close <window ID>. ParseControlNotification returns its arguments as window ID.

ControlNotificationUnlinkedWindowRenamed : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationUnlinkedWindowRenamed

ControlNotificationUnlinkedWindowRenamed identifies the %unlinked-window-renamed notification, available since tmux 3.2a. Its wire grammar is %unlinked-window-renamed <window ID> <name>. ParseControlNotification returns its arguments as window ID, name tail.

ControlNotificationWindowAdd : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationWindowAdd

ControlNotificationWindowAdd identifies the %window-add notification, available since tmux 3.2a. Its wire grammar is %window-add <window ID>. ParseControlNotification returns its arguments as window ID.

ControlNotificationWindowClose : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationWindowClose

ControlNotificationWindowClose identifies the %window-close notification, available since tmux 3.2a. Its wire grammar is %window-close <window ID>. ParseControlNotification returns its arguments as window ID.

ControlNotificationWindowPaneChanged : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationWindowPaneChanged

ControlNotificationWindowPaneChanged identifies the %window-pane-changed notification, available since tmux 3.2a. Its wire grammar is %window-pane-changed <window ID> <pane ID>. ParseControlNotification returns its arguments as window ID, pane ID.

ControlNotificationWindowRenamed : ControlNotificationKind
constant [source]
constant [source]
ControlNotificationWindowRenamed

ControlNotificationWindowRenamed identifies the %window-renamed notification, available since tmux 3.2a. Its wire grammar is %window-renamed <window ID> <name>. ParseControlNotification returns its arguments as window ID, name tail.

CopyModeLineNumbersAbsolute : CopyModeLineNumbers
constant [source]
constant [source]
CopyModeLineNumbersAbsolute

CopyModeLineNumbersAbsolute selects "absolute".

CopyModeLineNumbersDefault : CopyModeLineNumbers
constant [source]
constant [source]
CopyModeLineNumbersDefault

CopyModeLineNumbersDefault selects "default".

CopyModeLineNumbersHybrid : CopyModeLineNumbers
constant [source]
constant [source]
CopyModeLineNumbersHybrid

CopyModeLineNumbersHybrid selects "hybrid".

CopyModeLineNumbersOff : CopyModeLineNumbers
constant [source]
constant [source]
CopyModeLineNumbersOff

CopyModeLineNumbersOff selects "off".

CopyModeLineNumbersRelative : CopyModeLineNumbers
constant [source]
constant [source]
CopyModeLineNumbersRelative

CopyModeLineNumbersRelative selects "relative".

CursorStyleBar : CursorStyle
constant [source]
constant [source]
CursorStyleBar

CursorStyleBar selects "bar".

CursorStyleBlinkingBar : CursorStyle
constant [source]
constant [source]
CursorStyleBlinkingBar

CursorStyleBlinkingBar selects "blinking-bar".

CursorStyleBlinkingBlock : CursorStyle
constant [source]
constant [source]
CursorStyleBlinkingBlock

CursorStyleBlinkingBlock selects "blinking-block".

CursorStyleBlinkingUnderline : CursorStyle
constant [source]
constant [source]
CursorStyleBlinkingUnderline

CursorStyleBlinkingUnderline selects "blinking-underline".

CursorStyleBlock : CursorStyle
constant [source]
constant [source]
CursorStyleBlock

CursorStyleBlock selects "block".

CursorStyleDefault : CursorStyle
constant [source]
constant [source]
CursorStyleDefault

CursorStyleDefault selects "default".

CursorStyleUnderline : CursorStyle
constant [source]
constant [source]
CursorStyleUnderline

CursorStyleUnderline selects "underline".

DegradeUnsupported
constant [source]
constant [source]
DegradeUnsupported

DegradeUnsupported omits the capability, runs the reduced command, and reports the decision to ServerOptions.WarningHandler as a WarningUnsupportedFeature.

DestroyUnattachedKeepGroup : DestroyUnattached
constant [source]
constant [source]
DestroyUnattachedKeepGroup

DestroyUnattachedKeepGroup selects "keep-group".

DestroyUnattachedKeepLast : DestroyUnattached
constant [source]
constant [source]
DestroyUnattachedKeepLast

DestroyUnattachedKeepLast selects "keep-last".

DestroyUnattachedOff : DestroyUnattached
constant [source]
constant [source]
DestroyUnattachedOff

DestroyUnattachedOff selects "off".

DestroyUnattachedOn : DestroyUnattached
constant [source]
constant [source]
DestroyUnattachedOn

DestroyUnattachedOn selects "on".

DetachOnDestroyNext : DetachOnDestroy
constant [source]
constant [source]
DetachOnDestroyNext

DetachOnDestroyNext selects "next".

DetachOnDestroyNoDetached : DetachOnDestroy
constant [source]
constant [source]
DetachOnDestroyNoDetached

DetachOnDestroyNoDetached selects "no-detached".

DetachOnDestroyOff : DetachOnDestroy
constant [source]
constant [source]
DetachOnDestroyOff

DetachOnDestroyOff selects "off".

DetachOnDestroyOn : DetachOnDestroy
constant [source]
constant [source]
DetachOnDestroyOn

DetachOnDestroyOn selects "on".

DetachOnDestroyPrevious : DetachOnDestroy
constant [source]
constant [source]
DetachOnDestroyPrevious

DetachOnDestroyPrevious selects "previous".

ExtendedKeysAlways : ExtendedKeys
constant [source]
constant [source]
ExtendedKeysAlways

ExtendedKeysAlways selects "always".

ExtendedKeysFormatCSIU : ExtendedKeysFormat
constant [source]
constant [source]
ExtendedKeysFormatCSIU

ExtendedKeysFormatCSIU selects "csi-u".

ExtendedKeysFormatXTerm : ExtendedKeysFormat
constant [source]
constant [source]
ExtendedKeysFormatXTerm

ExtendedKeysFormatXTerm selects "xterm".

ExtendedKeysOff : ExtendedKeys
constant [source]
constant [source]
ExtendedKeysOff

ExtendedKeysOff selects "off".

ExtendedKeysOn : ExtendedKeys
constant [source]
constant [source]
ExtendedKeysOn

ExtendedKeysOn selects "on".

FailUnsupported : UnsupportedPolicy
constant [source]
constant [source]
FailUnsupported

FailUnsupported refuses a request naming a capability the running tmux does not have, with a VersionTooLowError naming the subcommand and the capability. It is the zero value.

FilterSchemaVersion
constant [source]
constant [source]
FilterSchemaVersion

FilterSchemaVersion identifies external metadata for the generated filter JSON wire schema. It is not embedded in JSON and is independent of the tmux Version .

GetClipboardBoth : GetClipboard
constant [source]
constant [source]
GetClipboardBoth

GetClipboardBoth selects "both".

GetClipboardBuffer : GetClipboard
constant [source]
constant [source]
GetClipboardBuffer

GetClipboardBuffer selects "buffer".

GetClipboardOff : GetClipboard
constant [source]
constant [source]
GetClipboardOff

GetClipboardOff selects "off".

GetClipboardRequest : GetClipboard
constant [source]
constant [source]
GetClipboardRequest

GetClipboardRequest selects "request".

MaximumTestedVersion
constant [source]
constant [source]
MaximumTestedVersion

MaximumTestedVersion is the newest numbered tmux feature level covered by this package's tests. That feature level is tested against tmux 3.7c.

MenuBorderLinesDouble : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesDouble

MenuBorderLinesDouble selects "double".

MenuBorderLinesHeavy : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesHeavy

MenuBorderLinesHeavy selects "heavy".

MenuBorderLinesNone : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesNone

MenuBorderLinesNone selects "none".

MenuBorderLinesPadded : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesPadded

MenuBorderLinesPadded selects "padded".

MenuBorderLinesRounded : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesRounded

MenuBorderLinesRounded selects "rounded".

MenuBorderLinesSimple : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesSimple

MenuBorderLinesSimple selects "simple".

MenuBorderLinesSingle : MenuBorderLines
constant [source]
constant [source]
MenuBorderLinesSingle

MenuBorderLinesSingle selects "single".

MessageLine0 : MessageLine
constant [source]
constant [source]
MessageLine0

MessageLine0 selects "0".

MessageLine1 : MessageLine
constant [source]
constant [source]
MessageLine1

MessageLine1 selects "1".

MessageLine2 : MessageLine
constant [source]
constant [source]
MessageLine2

MessageLine2 selects "2".

MessageLine3 : MessageLine
constant [source]
constant [source]
MessageLine3

MessageLine3 selects "3".

MessageLine4 : MessageLine
constant [source]
constant [source]
MessageLine4

MessageLine4 selects "4".

MinimumConnectionVersion
constant [source]
constant [source]
MinimumConnectionVersion

MinimumConnectionVersion is the oldest tmux feature level that supports terminal Connection ownership. Later releases may strengthen individual lifecycle guarantees without changing this floor.

MinimumSupportedVersion
constant [source]
constant [source]
MinimumSupportedVersion

MinimumSupportedVersion is the oldest tmux feature level supported by this package.

ModeKeysEmacs : ModeKeys
constant [source]
constant [source]
ModeKeysEmacs

ModeKeysEmacs selects "emacs".

ModeKeysVi : ModeKeys
constant [source]
constant [source]
ModeKeysVi

ModeKeysVi selects "vi".

ModulePath
constant [source]
constant [source]
ModulePath

ModulePath is the Go module this package belongs to. It is the module path rather than the package path, because that is what Go build metadata records.

NewWindowDirectionAfter
constant [source]
constant [source]
NewWindowDirectionAfter

NewWindowDirectionAfter places the new winlink after the target.

NewWindowDirectionBefore
constant [source]
constant [source]
NewWindowDirectionBefore

NewWindowDirectionBefore places the new winlink before the target.

NewWindowDirectionDefault : NewWindowDirection
constant [source]
constant [source]
NewWindowDirectionDefault

NewWindowDirectionDefault uses the next free index with Session.NewWindow when Index is nil; Window.NewWindow instead keeps the receiver's exact occupied target.

OpComplete : OpStatus
constant [source]
constant [source]
OpComplete

OpComplete is an operation tmux ran successfully.

OpFailed
constant [source]
constant [source]
OpFailed

OpFailed is an operation tmux refused. Only an operation sent alone can receive this status.

OpIndeterminate
constant [source]
constant [source]
OpIndeterminate

OpIndeterminate is an operation dispatched without enough reply evidence to prove whether tmux applied or rejected it.

OpSkipped
constant [source]
constant [source]
OpSkipped

OpSkipped is an operation the plan did not dispatch because an earlier dispatch failed or became indeterminate.

OptionOriginInherited
constant [source]
constant [source]
OptionOriginInherited

OptionOriginInherited identifies a value inherited from a parent scope.

OptionOriginLocal : OptionOrigin
constant [source]
constant [source]
OptionOriginLocal

OptionOriginLocal identifies a value set directly at the queried scope.

PaneBorderIndicatorsArrows : PaneBorderIndicators
constant [source]
constant [source]
PaneBorderIndicatorsArrows

PaneBorderIndicatorsArrows selects "arrows".

PaneBorderIndicatorsBoth : PaneBorderIndicators
constant [source]
constant [source]
PaneBorderIndicatorsBoth

PaneBorderIndicatorsBoth selects "both".

PaneBorderIndicatorsColour : PaneBorderIndicators
constant [source]
constant [source]
PaneBorderIndicatorsColour

PaneBorderIndicatorsColour selects "colour".

PaneBorderIndicatorsOff : PaneBorderIndicators
constant [source]
constant [source]
PaneBorderIndicatorsOff

PaneBorderIndicatorsOff selects "off".

PaneBorderLinesDouble : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesDouble

PaneBorderLinesDouble selects "double".

PaneBorderLinesHeavy : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesHeavy

PaneBorderLinesHeavy selects "heavy".

PaneBorderLinesNumber : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesNumber

PaneBorderLinesNumber selects "number".

PaneBorderLinesSimple : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesSimple

PaneBorderLinesSimple selects "simple".

PaneBorderLinesSingle : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesSingle

PaneBorderLinesSingle selects "single".

PaneBorderLinesSpaces : PaneBorderLines
constant [source]
constant [source]
PaneBorderLinesSpaces

PaneBorderLinesSpaces selects "spaces".

PaneBorderStatusBottom : PaneBorderStatus
constant [source]
constant [source]
PaneBorderStatusBottom

PaneBorderStatusBottom selects "bottom".

PaneBorderStatusOff : PaneBorderStatus
constant [source]
constant [source]
PaneBorderStatusOff

PaneBorderStatusOff selects "off".

PaneBorderStatusTop : PaneBorderStatus
constant [source]
constant [source]
PaneBorderStatusTop

PaneBorderStatusTop selects "top".

PaneDirectionAbove
constant [source]
constant [source]
PaneDirectionAbove

PaneDirectionAbove places the pane above the target.

PaneDirectionBelow : PaneDirection
constant [source]
constant [source]
PaneDirectionBelow

PaneDirectionBelow places the pane below the target.

PaneDirectionLeft
constant [source]
constant [source]
PaneDirectionLeft

PaneDirectionLeft places the pane to the left of the target.

PaneDirectionRight
constant [source]
constant [source]
PaneDirectionRight

PaneDirectionRight places the pane to the right of the target.

PaneInputDisable
constant [source]
constant [source]
PaneInputDisable

PaneInputDisable disables input without selecting the target pane.

PaneInputEnable
constant [source]
constant [source]
PaneInputEnable

PaneInputEnable enables input without selecting the target pane.

PaneInputUnchanged : PaneInputMode
constant [source]
constant [source]
PaneInputUnchanged

PaneInputUnchanged leaves the target pane's input state unchanged.

PaneMarkClear
constant [source]
constant [source]
PaneMarkClear

PaneMarkClear clears the server-wide marked pane without selecting the target.

PaneMarkSet
constant [source]
constant [source]
PaneMarkSet

PaneMarkSet makes the target the server-wide marked pane without selecting it.

PaneMarkUnchanged : PaneMarkMode
constant [source]
constant [source]
PaneMarkUnchanged

PaneMarkUnchanged leaves the server-wide marked pane unchanged.

PaneResizeDirectionDown
constant [source]
constant [source]
PaneResizeDirectionDown

PaneResizeDirectionDown selects tmux's downward adjustment.

PaneResizeDirectionLeft
constant [source]
constant [source]
PaneResizeDirectionLeft

PaneResizeDirectionLeft selects tmux's leftward adjustment.

PaneResizeDirectionNone : PaneResizeDirection
constant [source]
constant [source]
PaneResizeDirectionNone

PaneResizeDirectionNone omits a directional resize.

PaneResizeDirectionRight
constant [source]
constant [source]
PaneResizeDirectionRight

PaneResizeDirectionRight selects tmux's rightward adjustment.

PaneResizeDirectionUp
constant [source]
constant [source]
PaneResizeDirectionUp

PaneResizeDirectionUp selects tmux's upward adjustment.

PaneScrollbarsModal : PaneScrollbars
constant [source]
constant [source]
PaneScrollbarsModal

PaneScrollbarsModal selects "modal".

PaneScrollbarsOff : PaneScrollbars
constant [source]
constant [source]
PaneScrollbarsOff

PaneScrollbarsOff selects "off".

PaneScrollbarsOn : PaneScrollbars
constant [source]
constant [source]
PaneScrollbarsOn

PaneScrollbarsOn selects "on".

PaneScrollbarsPositionLeft : PaneScrollbarsPosition
constant [source]
constant [source]
PaneScrollbarsPositionLeft

PaneScrollbarsPositionLeft selects "left".

PaneScrollbarsPositionRight : PaneScrollbarsPosition
constant [source]
constant [source]
PaneScrollbarsPositionRight

PaneScrollbarsPositionRight selects "right".

PaneSelectDirectionDown
constant [source]
constant [source]
PaneSelectDirectionDown

PaneSelectDirectionDown selects the pane below the target.

PaneSelectDirectionLast
constant [source]
constant [source]
PaneSelectDirectionLast

PaneSelectDirectionLast selects the previously active pane.

PaneSelectDirectionLeft
constant [source]
constant [source]
PaneSelectDirectionLeft

PaneSelectDirectionLeft selects the pane to the left of the target.

PaneSelectDirectionNone : PaneSelectDirection
constant [source]
constant [source]
PaneSelectDirectionNone

PaneSelectDirectionNone selects no relative pane.

PaneSelectDirectionRight
constant [source]
constant [source]
PaneSelectDirectionRight

PaneSelectDirectionRight selects the pane to the right of the target.

PaneSelectDirectionUp
constant [source]
constant [source]
PaneSelectDirectionUp

PaneSelectDirectionUp selects the pane above the target.

PopupBorderLinesDouble : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesDouble

PopupBorderLinesDouble selects "double".

PopupBorderLinesHeavy : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesHeavy

PopupBorderLinesHeavy selects "heavy".

PopupBorderLinesNone : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesNone

PopupBorderLinesNone selects "none".

PopupBorderLinesPadded : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesPadded

PopupBorderLinesPadded selects "padded".

PopupBorderLinesRounded : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesRounded

PopupBorderLinesRounded selects "rounded".

PopupBorderLinesSimple : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesSimple

PopupBorderLinesSimple selects "simple".

PopupBorderLinesSingle : PopupBorderLines
constant [source]
constant [source]
PopupBorderLinesSingle

PopupBorderLinesSingle selects "single".

PrefixPrimary : PrefixKey
constant [source]
constant [source]
PrefixPrimary

PrefixPrimary selects tmux's primary prefix key.

PrefixSecondary
constant [source]
constant [source]
PrefixSecondary

PrefixSecondary selects tmux's secondary prefix key.

PromptCommandCursorStyleBar : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleBar

PromptCommandCursorStyleBar selects "bar".

PromptCommandCursorStyleBlinkingBar : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleBlinkingBar

PromptCommandCursorStyleBlinkingBar selects "blinking-bar".

PromptCommandCursorStyleBlinkingBlock : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleBlinkingBlock

PromptCommandCursorStyleBlinkingBlock selects "blinking-block".

PromptCommandCursorStyleBlinkingUnderline : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleBlinkingUnderline

PromptCommandCursorStyleBlinkingUnderline selects "blinking-underline".

PromptCommandCursorStyleBlock : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleBlock

PromptCommandCursorStyleBlock selects "block".

PromptCommandCursorStyleDefault : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleDefault

PromptCommandCursorStyleDefault selects "default".

PromptCommandCursorStyleUnderline : PromptCommandCursorStyle
constant [source]
constant [source]
PromptCommandCursorStyleUnderline

PromptCommandCursorStyleUnderline selects "underline".

PromptCursorStyleBar : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleBar

PromptCursorStyleBar selects "bar".

PromptCursorStyleBlinkingBar : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleBlinkingBar

PromptCursorStyleBlinkingBar selects "blinking-bar".

PromptCursorStyleBlinkingBlock : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleBlinkingBlock

PromptCursorStyleBlinkingBlock selects "blinking-block".

PromptCursorStyleBlinkingUnderline : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleBlinkingUnderline

PromptCursorStyleBlinkingUnderline selects "blinking-underline".

PromptCursorStyleBlock : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleBlock

PromptCursorStyleBlock selects "block".

PromptCursorStyleDefault : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleDefault

PromptCursorStyleDefault selects "default".

PromptCursorStyleUnderline : PromptCursorStyle
constant [source]
constant [source]
PromptCursorStyleUnderline

PromptCursorStyleUnderline selects "underline".

PromptTypeAll : PromptType
constant [source]
constant [source]
PromptTypeAll

PromptTypeAll selects every prompt-history class and omits -T.

PromptTypeCommand
constant [source]
constant [source]
PromptTypeCommand

PromptTypeCommand selects command-prompt history.

PromptTypeSearch
constant [source]
constant [source]
PromptTypeSearch

PromptTypeSearch selects search-prompt history.

PromptTypeTarget
constant [source]
constant [source]
PromptTypeTarget

PromptTypeTarget selects target-prompt history.

PromptTypeWindowTarget
constant [source]
constant [source]
PromptTypeWindowTarget

PromptTypeWindowTarget selects window-target-prompt history.

RemainOnExitFailed : RemainOnExit
constant [source]
constant [source]
RemainOnExitFailed

RemainOnExitFailed selects "failed".

RemainOnExitKey : RemainOnExit
constant [source]
constant [source]
RemainOnExitKey

RemainOnExitKey selects "key".

RemainOnExitOff : RemainOnExit
constant [source]
constant [source]
RemainOnExitOff

RemainOnExitOff selects "off".

RemainOnExitOn : RemainOnExit
constant [source]
constant [source]
RemainOnExitOn

RemainOnExitOn selects "on".

RotateWindowDefault : RotateWindowDirection
constant [source]
constant [source]
RotateWindowDefault

RotateWindowDefault uses tmux's default rotation.

RotateWindowDown
constant [source]
constant [source]
RotateWindowDown

RotateWindowDown rotates pane positions toward higher indexes.

RotateWindowUp
constant [source]
constant [source]
RotateWindowUp

RotateWindowUp rotates pane positions toward lower indexes.

SetClipboardExternal : SetClipboard
constant [source]
constant [source]
SetClipboardExternal

SetClipboardExternal selects "external".

SetClipboardOff : SetClipboard
constant [source]
constant [source]
SetClipboardOff

SetClipboardOff selects "off".

SetClipboardOn : SetClipboard
constant [source]
constant [source]
SetClipboardOn

SetClipboardOn selects "on".

ShellPrompt
constant [source]
constant [source]
ShellPrompt

ShellPrompt is the prompt drawn when ServerOptions.FixedShell is enabled.

SilenceActionAny : SilenceAction
constant [source]
constant [source]
SilenceActionAny

SilenceActionAny selects "any".

SilenceActionCurrent : SilenceAction
constant [source]
constant [source]
SilenceActionCurrent

SilenceActionCurrent selects "current".

SilenceActionNone : SilenceAction
constant [source]
constant [source]
SilenceActionNone

SilenceActionNone selects "none".

SilenceActionOther : SilenceAction
constant [source]
constant [source]
SilenceActionOther

SilenceActionOther selects "other".

Status2 : Status
constant [source]
constant [source]
Status2

Status2 selects "2".

Status3 : Status
constant [source]
constant [source]
Status3

Status3 selects "3".

Status4 : Status
constant [source]
constant [source]
Status4

Status4 selects "4".

Status5 : Status
constant [source]
constant [source]
Status5

Status5 selects "5".

StatusJustifyAbsoluteCentre : StatusJustify
constant [source]
constant [source]
StatusJustifyAbsoluteCentre

StatusJustifyAbsoluteCentre selects "absolute-centre".

StatusJustifyCentre : StatusJustify
constant [source]
constant [source]
StatusJustifyCentre

StatusJustifyCentre selects "centre".

StatusJustifyLeft : StatusJustify
constant [source]
constant [source]
StatusJustifyLeft

StatusJustifyLeft selects "left".

StatusJustifyRight : StatusJustify
constant [source]
constant [source]
StatusJustifyRight

StatusJustifyRight selects "right".

StatusKeysEmacs : StatusKeys
constant [source]
constant [source]
StatusKeysEmacs

StatusKeysEmacs selects "emacs".

StatusKeysVi : StatusKeys
constant [source]
constant [source]
StatusKeysVi

StatusKeysVi selects "vi".

StatusOff : Status
constant [source]
constant [source]
StatusOff

StatusOff selects "off".

StatusOn : Status
constant [source]
constant [source]
StatusOn

StatusOn selects "on".

StatusPositionBottom : StatusPosition
constant [source]
constant [source]
StatusPositionBottom

StatusPositionBottom selects "bottom".

StatusPositionTop : StatusPosition
constant [source]
constant [source]
StatusPositionTop

StatusPositionTop selects "top".

SuiteRootTagVariable
constant [source]
constant [source]
SuiteRootTagVariable

SuiteRootTagVariable names the environment variable that tags a suite's temporary root. go test runs packages in parallel and every suite among them creates a root beside the others, so a test spawning a child suite sets this to tell its child's root from theirs.

SwapPaneDirectionDown
constant [source]
constant [source]
SwapPaneDirectionDown

SwapPaneDirectionDown swaps with the next pane in index order.

SwapPaneDirectionNone : SwapPaneDirection
constant [source]
constant [source]
SwapPaneDirectionNone

SwapPaneDirectionNone selects no adjacent pane.

SwapPaneDirectionUp
constant [source]
constant [source]
SwapPaneDirectionUp

SwapPaneDirectionUp swaps with the previous pane in index order.

TemporaryNamePrefix
constant [source]
constant [source]
TemporaryNamePrefix

TemporaryNamePrefix prefixes names generated by NewSession and NewWindow .

TerminalOverrideValueFlag : TerminalOverrideValueKind
constant [source]
constant [source]
TerminalOverrideValueFlag

TerminalOverrideValueFlag identifies a capability without an assigned value.

TerminalOverrideValueInteger
constant [source]
constant [source]
TerminalOverrideValueInteger

TerminalOverrideValueInteger identifies an unsigned decimal integer.

TerminalOverrideValueText
constant [source]
constant [source]
TerminalOverrideValueText

TerminalOverrideValueText identifies an assigned non-integer string.

TreeSortDefault : TreeSortOrder
constant [source]
constant [source]
TreeSortDefault

TreeSortDefault leaves the configured choose-tree ordering unchanged.

TreeSortIndex
constant [source]
constant [source]
TreeSortIndex

TreeSortIndex orders tree entries by index.

TreeSortName
constant [source]
constant [source]
TreeSortName

TreeSortName orders tree entries by name.

TreeSortSize
constant [source]
constant [source]
TreeSortSize

TreeSortSize orders tree entries by size.

TreeSortTime
constant [source]
constant [source]
TreeSortTime

TreeSortTime orders tree entries by activity time.

VisualActivityBoth : VisualActivity
constant [source]
constant [source]
VisualActivityBoth

VisualActivityBoth selects "both".

VisualActivityOff : VisualActivity
constant [source]
constant [source]
VisualActivityOff

VisualActivityOff selects "off".

VisualActivityOn : VisualActivity
constant [source]
constant [source]
VisualActivityOn

VisualActivityOn selects "on".

VisualBellBoth : VisualBell
constant [source]
constant [source]
VisualBellBoth

VisualBellBoth selects "both".

VisualBellOff : VisualBell
constant [source]
constant [source]
VisualBellOff

VisualBellOff selects "off".

VisualBellOn : VisualBell
constant [source]
constant [source]
VisualBellOn

VisualBellOn selects "on".

VisualSilenceBoth : VisualSilence
constant [source]
constant [source]
VisualSilenceBoth

VisualSilenceBoth selects "both".

VisualSilenceOff : VisualSilence
constant [source]
constant [source]
VisualSilenceOff

VisualSilenceOff selects "off".

VisualSilenceOn : VisualSilence
constant [source]
constant [source]
VisualSilenceOn

VisualSilenceOn selects "on".

WaitForModeLock
constant [source]
constant [source]
WaitForModeLock

WaitForModeLock acquires Channel's tmux mutex.

WaitForModeSignal
constant [source]
constant [source]
WaitForModeSignal

WaitForModeSignal signals Channel and wakes waiters.

WaitForModeUnlock
constant [source]
constant [source]
WaitForModeUnlock

WaitForModeUnlock releases Channel's tmux mutex.

WaitForModeWait : WaitForMode
constant [source]
constant [source]
WaitForModeWait

WaitForModeWait waits until another client signals Channel.

WarningCommandStderr
constant [source]
constant [source]
WarningCommandStderr

WarningCommandStderr reports stderr from a completed command whose Python API treats the diagnostic as nonfatal.

WarningUnsupportedFeature : WarningKind
constant [source]
constant [source]
WarningUnsupportedFeature

WarningUnsupportedFeature reports a requested feature omitted because the connected tmux binary is too old.

WindowResizeDirectionDown
constant [source]
constant [source]
WindowResizeDirectionDown

WindowResizeDirectionDown adjusts the window downward.

WindowResizeDirectionLeft
constant [source]
constant [source]
WindowResizeDirectionLeft

WindowResizeDirectionLeft adjusts the window leftward.

WindowResizeDirectionNone : WindowResizeDirection
constant [source]
constant [source]
WindowResizeDirectionNone

WindowResizeDirectionNone selects no directional adjustment.

WindowResizeDirectionRight
constant [source]
constant [source]
WindowResizeDirectionRight

WindowResizeDirectionRight adjusts the window rightward.

WindowResizeDirectionUp
constant [source]
constant [source]
WindowResizeDirectionUp

WindowResizeDirectionUp adjusts the window upward.

WindowSizeLargest : WindowSize
constant [source]
constant [source]
WindowSizeLargest

WindowSizeLargest selects "largest".

WindowSizeLatest : WindowSize
constant [source]
constant [source]
WindowSizeLatest

WindowSizeLatest selects "latest".

WindowSizeManual : WindowSize
constant [source]
constant [source]
WindowSizeManual

WindowSizeManual selects "manual".

WindowSizeSmallest : WindowSize
constant [source]
constant [source]
WindowSizeSmallest

WindowSizeSmallest selects "smallest".

Build ( ctx : context.Context , server : tmux.Server , workspace : Workspace ) (tmux.Session, error)
function [source]
function [source]
Build

Build creates the workspace on server and returns the created session.

Build is not atomic. A failure after session creation returns that session; completed mutations remain in tmux. Command failures are not normalized.

Build creates the session and an attached control connection in one process, uses that connection for the build, and closes it before returning. The returned Session is not bound to the closed connection. Build verifies that the session remains reachable after closing it. An attached connection may fire client hooks and policies.

Each pane receives workspace, window, and pane CommandsBefore, then its own Commands. Sleep values pause Build rather than the pane.

Discussed in Build a workspace from a file

BuildInto ( ctx : context.Context , session : tmux.Session , workspace : Workspace ) error
function [source]
function [source]
BuildInto

BuildInto populates the initial session described by workspace. The session must already have been created from Workspace.InitialSessionRequest . BuildInto uses the session's existing server and transport; it neither creates a session nor opens or owns a connection.

BuildInto is not atomic. A failure leaves completed mutations in tmux.

CaptureLine ( line : int ) CapturePosition
function [source]
function [source]
CaptureLine

CaptureLine returns the canonical tmux representation of a capture line. Zero is the first visible line; negative values address history.

ClientNameIs ( value : ClientName ) ClientFilter
function [source]
function [source]
ClientNameIs

ClientNameIs returns a ClientFilter that exactly matches the stable tmux client name from Client.Name. It sets no other criteria and does not validate value.

ClientReadOnlyIs ( value : bool ) ClientFilter
function [source]
function [source]
ClientReadOnlyIs

ClientReadOnlyIs returns a ClientFilter that exactly matches the materialized read-only state from Client.ReadOnly. It sets no other criteria and does not validate value.

ExactlyOne ( values : []T , predicate : func(*T) bool ) (T, error)
function [source]
function [source]
ExactlyOne

ExactlyOne returns a shallow copy when exactly one source-ordered value is accepted by predicate. It examines values until source exhaustion confirms a sole match, or stops at the second match. It returns the zero value of T with ErrNoMatch for no matches or ErrMultipleMatches for multiple matches; callers can classify either error with errors.Is.

Discussed in Filtering and querying, in practice

ExactlyOneSeq ( values : iter.Seq[T] , predicate : func(*T) bool ) (T, error)
function [source]
function [source]
ExactlyOneSeq

ExactlyOneSeq returns a shallow copy when exactly one source-ordered sequence value is accepted by predicate. It stops pulling at the second match. If input ends with no matches, it returns the zero value of T with ErrNoMatch; if it finds a second match, it returns the zero value of T with ErrMultipleMatches. Callers can classify either error with errors.Is. With an infinite input, ExactlyOneSeq returns only after a second match; it cannot confirm a no-match or exactly-one result without source exhaustion.

First ( values : []T , predicate : func(*T) bool ) (T, bool)
function [source]
function [source]
First

First returns a shallow copy of the first source-ordered value accepted by predicate and stops evaluating later values. If no value matches, it returns the zero value of T and false.

FirstSeq ( values : iter.Seq[T] , predicate : func(*T) bool ) (T, bool)
function [source]
function [source]
FirstSeq

FirstSeq returns a shallow copy of the first source-ordered sequence value accepted by predicate and stops pulling later values. If no value matches, it returns the zero value of T and false. With an infinite input that never matches, FirstSeq does not return.

Main ( m : *testing.M ) int
function [source]
function [source]
Main

Main runs the one-call package lifecycle for tmuxtest. It prepares short temporary paths, redirects suiteEnvironment into them, runs m, cleans registered servers, restores the environment, and returns the final status. TestMain should return its result through os.Exit.

NewControlMode ( ctx : context.Context , t : testing.TB , server : tmux.Server , session : tmux.Session ) *ControlMode
function [source]
function [source]
NewControlMode

NewControlMode starts a ControlMode attached to session and registers cleanup with t. It requires an explicitly configured process environment and validates that session belongs to server. The client pins the server's frozen effective socket path. Validation or startup failures call testing.TB.Fatal. ctx bounds startup and registration only, not the returned client's lifetime.

NewPlan ( ) *Plan
function [source]
function [source]
NewPlan

NewPlan returns an empty Plan .

NewServer ( options : ServerOptions ) (Server, error)
function [source]
function [source]
NewServer

NewServer validates and snapshots one tmux configuration without starting tmux. Empty socket selectors use the endpoint selected by the frozen environment.

Discussed in Socket and servers

NewServer ( ctx : context.Context , t : testing.TB ) tmux.Server
function [source]
function [source]
NewServer

NewServer starts an isolated tmux.Server with a session named "work". Startup uses ctx and the harness timeout, whichever ends first. It registers bounded cleanup with t; setup failures call testing.TB.Fatal. The context does not govern later server cleanup or daemon lifetime.

NewServerFromEnv ( environment : map[string]string ) (Server, error)
function [source]
function [source]
NewServerFromEnv

NewServerFromEnv returns a server configured from TMUX without starting tmux. It snapshots the process environment once. A nonnil environment supplies discovery values and overrides that snapshot for later tmux processes; an empty map therefore has no TMUX discovery value. Names follow the platform's environment rules and are case-insensitive on Windows.

Discussed in Environment

NewServerWithOptions ( ctx : context.Context , t : testing.TB , options : ServerOptions ) tmux.Server
function [source]
function [source]
NewServerWithOptions

NewServerWithOptions prepares an isolated harness-owned tmux.Server from options. Initial startup uses ctx and the harness timeout, whichever ends first. The daemon starts only when ServerOptions.InitialSession is non-nil or a later tmux command starts it. It registers bounded cleanup with t; setup failures call testing.TB.Fatal. The context does not govern later cleanup or daemon lifetime.

NewSession ( ctx : context.Context , t : testing.TB , server : tmux.Server , request : tmux.NewSessionRequest ) tmux.Session
function [source]
function [source]
NewSession

NewSession creates a test-owned tmux.Session and registers cleanup against its stable ID. An empty tmux.NewSessionRequest.Name receives a collision-checked temporary name. The request and referenced values are copied before tmux is called, and setup failures call testing.TB.Fatal. Cleanup belongs to t rather than ctx and continues to target the session if it is renamed.

NewSparseArray ( entries : SparseEntry[T] ) (SparseArray[T], error)
function [source]
function [source]
NewSparseArray

NewSparseArray builds an array from entries, sorting them by index. It returns errors matching ErrInvalidSparseIndex or ErrDuplicateSparseIndex for negative, overflowing, or duplicate indices.

NewWindow ( ctx : context.Context , t : testing.TB , session : tmux.Session , request : tmux.NewWindowRequest ) tmux.Window
function [source]
function [source]
NewWindow

NewWindow creates a test-owned tmux.Window and registers cleanup against its stable ID. A nil tmux.NewWindowRequest.Name receives a collision-checked temporary name; an empty non-nil name remains explicit. The request and referenced values are copied before tmux is called, and setup failures call testing.TB.Fatal. Cleanup belongs to t rather than ctx and follows the window if it is moved.

PackageVersion ( ) (string, bool)
function [source]
function [source]
PackageVersion

PackageVersion returns the release version recorded in Go build metadata. Development builds and binaries without module metadata return "", false.

PaneActiveIs ( value : bool ) PaneFilter
function [source]
function [source]
PaneActiveIs

PaneActiveIs returns a PaneFilter that exactly matches the materialized active state from Pane.Active. It sets no other criteria and does not validate value.

PaneCells ( cells : int ) PaneSize
function [source]
function [source]
PaneCells

PaneCells returns an explicit pane size measured in cells. Resize validates that cells is nonnegative; zero remains an explicit request.

PaneCommandIs ( value : string ) PaneFilter
function [source]
function [source]
PaneCommandIs

PaneCommandIs returns a PaneFilter that exactly matches the materialized current command from Pane.CurrentCommand. It sets no other criteria and does not validate value.

PaneFromEnv ( ctx : context.Context , environment : map[string]string ) (Pane, error)
function [source]
function [source]
PaneFromEnv

PaneFromEnv returns the pane identified by TMUX and TMUX_PANE. Nil reads the process environment; a nonnil empty map does not. Environment names are case-insensitive on Windows. It resolves the live hierarchy later through identity-checked tmux queries.

Discussed in Environment

PaneIDIs ( value : PaneID ) PaneFilter
function [source]
function [source]
PaneIDIs

PaneIDIs returns a PaneFilter that exactly matches the stable tmux pane identifier from Pane.ID, including its % sigil. It sets no other criteria and does not validate value.

PaneIndexIs ( value : int ) PaneFilter
function [source]
function [source]
PaneIndexIs

PaneIndexIs returns a PaneFilter that exactly matches the nonnegative pane index from Pane.Index. It sets no other criteria and does not validate value.

PanePercent ( percent : int ) PaneSize
function [source]
function [source]
PanePercent

PanePercent returns an explicit percentage of the window size. Resize validates that percent is between 0 and 100 inclusive; zero remains an explicit request.

PaneRef ( id : PaneID ) Ref
function [source]
function [source]
PaneRef

PaneRef returns a selector-relative Ref addressing a pane by ID, for a caller holding an identifier rather than a materialized record.

PaneSessionIDIs ( value : SessionID ) PaneFilter
function [source]
function [source]
PaneSessionIDIs

PaneSessionIDIs returns a PaneFilter that exactly matches the stable tmux session identifier from Pane.SessionID, including its $ sigil. It sets no other criteria and does not validate value.

PaneTitleIs ( value : string ) PaneFilter
function [source]
function [source]
PaneTitleIs

PaneTitleIs returns a PaneFilter that exactly matches the materialized title from Pane.Title. It sets no other criteria and does not validate value.

PaneWindowIDIs ( value : WindowID ) PaneFilter
function [source]
function [source]
PaneWindowIDIs

PaneWindowIDIs returns a PaneFilter that exactly matches the stable tmux window identifier from Pane.WindowID, including its @ sigil. It sets no other criteria and does not validate value.

PaneWindowIndexIs ( value : int ) PaneFilter
function [source]
function [source]
PaneWindowIndexIs

PaneWindowIndexIs returns a PaneFilter that exactly matches the nonnegative winlink index from Pane.WindowIndex. It sets no other criteria and does not validate value.

Parse ( document : []byte ) (Workspace, error)
function [source]
function [source]
Parse

Parse decodes one workspace document. Unknown fields are rejected so a misspelled key fails loudly instead of being dropped.

Discussed in Build a workspace from a file

ParseClientLookup ( lookup : string , values : string ) (ClientFilter, error)
function [source]
function [source]
ParseClientLookup

ParseClientLookup converts a lookup path into a concrete client filter. Paths traverse generated JSON relation names and separate segments with double underscores. The default operator is exact. Accepted suffixes are eq, exact, iexact, contains, icontains, startswith, istartswith, endswith, iendswith, in, nin, regex, and iregex; availability is field-specific. The eq suffix aliases exact, nin negates in, scalar operators require one value, and in and nin require one or more. Invalid paths, operators, values, or results wrap ErrInvalidFilter.

ParseControlNotification ( line : []byte ) (ControlNotification, error)
function [source]
function [source]
ParseControlNotification

ParseControlNotification parses one newline-free tmux control-mode notification record. It requires exact control framing and a supported kind, returns errors compatible with ErrMalformedControlNotification or ErrUnknownControlNotification, and copies all caller-owned input before returning. It never returns a partial notification.

ParsePaneLookup ( lookup : string , values : string ) (PaneFilter, error)
function [source]
function [source]
ParsePaneLookup

ParsePaneLookup converts a lookup path into a concrete pane filter. Paths traverse generated JSON relation names and separate segments with double underscores. The default operator is exact. Accepted suffixes are eq, exact, iexact, contains, icontains, startswith, istartswith, endswith, iendswith, in, nin, regex, and iregex; availability is field-specific. The eq suffix aliases exact, nin negates in, scalar operators require one value, and in and nin require one or more. Invalid paths, operators, values, or results wrap ErrInvalidFilter.

ParseSessionLookup ( lookup : string , values : string ) (SessionFilter, error)
function [source]
function [source]
ParseSessionLookup

ParseSessionLookup converts a lookup path into a concrete session filter. Paths traverse generated JSON relation names and separate segments with double underscores. The default operator is exact. Accepted suffixes are eq, exact, iexact, contains, icontains, startswith, istartswith, endswith, iendswith, in, nin, regex, and iregex; availability is field-specific. The eq suffix aliases exact, nin negates in, scalar operators require one value, and in and nin require one or more. Invalid paths, operators, values, or results wrap ErrInvalidFilter.

ParseVersion ( raw : string ) (Version, error)
function [source]
function [source]
ParseVersion

ParseVersion parses a raw tmux version token. It returns a VersionError matching ErrInvalidVersion when the token cannot be parsed.

ParseWindowLookup ( lookup : string , values : string ) (WindowFilter, error)
function [source]
function [source]
ParseWindowLookup

ParseWindowLookup converts a lookup path into a concrete window filter. Paths traverse generated JSON relation names and separate segments with double underscores. The default operator is exact. Accepted suffixes are eq, exact, iexact, contains, icontains, startswith, istartswith, endswith, iendswith, in, nin, regex, and iregex; availability is field-specific. The eq suffix aliases exact, nin negates in, scalar operators require one value, and in and nin require one or more. Invalid paths, operators, values, or results wrap ErrInvalidFilter.

Poll ( ctx : context.Context , interval : time.Duration , condition : func(context.Context) (bool, error) ) error
function [source]
function [source]
Poll

Poll checks condition immediately and then after each interval, until it reports true, returns an error, or ctx ends.

A condition receives ctx and must observe cancellation itself; Poll cannot interrupt one already running. Poll returns condition errors unchanged and ctx.Err when ctx ends first. Use Poll to wait for pane output; Server.WaitFor signals tmux's separate wait-for channel.

Ptr ( value : T ) *T
function [source]
function [source]
Ptr

Ptr returns a distinct pointer to a shallow copy of value, including when T has zero size. Its nonzero holder prevents Go from coalescing zero-size addresses. Slices, maps, pointers, and other reference-bearing values still alias their referenced data. Ptr performs no validation or ownership transfer.

RunInPane ( ctx : context.Context , t : testing.TB , command : string ) tmux.Pane
function [source]
function [source]
RunInPane

RunInPane creates an isolated pane, waits for its startup-file-free POSIX shell, and submits command with Type . It does not wait for command to start or finish. Resources belong to t; setup failures call testing.TB.Fatal. Use NewServerWithOptions for custom topology or configuration.

Screen ( ctx : context.Context , t : testing.TB , pane : tmux.Pane ) []string
function [source]
function [source]
Screen

Screen returns the pane's visible lines, top to bottom, with tmux's trailing blank lines removed.

Scrolled-out output is excluded. Use tmux.Pane.Capture with tmux.CaptureBoundary to read scrollback.

Read failures call testing.TB.Fatal.

SessionAttachedIs ( value : bool ) SessionFilter
function [source]
function [source]
SessionAttachedIs

SessionAttachedIs returns a SessionFilter that exactly matches the materialized attachment state from Session.Attached. It sets no other criteria and does not validate value.

SessionFromEnv ( ctx : context.Context , environment : map[string]string ) (Session, error)
function [source]
function [source]
SessionFromEnv

SessionFromEnv returns the canonical session containing the environment's pane. Nil reads the process environment; a nonnil empty map does not.

Discussed in Environment

SessionIDIs ( value : SessionID ) SessionFilter
function [source]
function [source]
SessionIDIs

SessionIDIs returns a SessionFilter that exactly matches the stable tmux session identifier from Session.ID, including its $ sigil. It sets no other criteria and does not validate value.

SessionNameIs ( value : string ) SessionFilter
function [source]
function [source]
SessionNameIs

SessionNameIs returns a SessionFilter that exactly matches the materialized session name from Session.Name. It sets no other criteria and does not validate value.

SessionRef ( id : SessionID ) Ref
function [source]
function [source]
SessionRef

SessionRef returns a selector-relative Ref addressing a session by ID, for a caller holding an identifier rather than a materialized record.

StartPTYProcess ( ctx : context.Context , t : testing.TB , binary : string , arguments : []string , environment : []string ) *PTYProcess
function [source]
function [source]
StartPTYProcess

StartPTYProcess starts binary with a harness-owned controlling terminal and registers bounded cleanup with t. Its start context owns the child lifetime: canceling ctx terminates the child. Arguments and environment are copied. A nil environment inherits the current process environment; a non-nil empty environment remains empty. binary runs directly without a shell. The PTY backend is supported on Linux only; unsupported platforms call testing.TB.Fatal. Setup failures also call testing.TB.Fatal.

Type ( ctx : context.Context , t : testing.TB , pane : tmux.Pane , command : string )
function [source]
function [source]
Type

Type sends command to the pane and submits it, as a person at the keyboard would.

command is sent literally. Type returns when tmux accepts the keys, before the shell finishes; follow it with a wait when completion matters.

TypeAndWait ( ctx : context.Context , t : testing.TB , pane : tmux.Pane , command : string )
function [source]
function [source]
TypeAndWait

TypeAndWait sends command to the pane and blocks until it has finished.

It appends and waits for a unique marker whether the command succeeds or fails. It does not return the command's exit status.

ValidateSessionName ( name : string ) error
function [source]
function [source]
ValidateSessionName

ValidateSessionName reports whether name can be used as a tmux session name. Empty names, the target delimiters '.' and ':', control characters and invalid UTF-8 are rejected.

WaitFor ( ctx : context.Context , interval : time.Duration , condition : func(context.Context) (bool, error) ) error
function [source]
function [source]
WaitFor

WaitFor checks condition serially and immediately, then after each interval, until it succeeds, returns an error, or ctx ends. It validates interval, condition, and ctx in that order: interval must be positive, condition must be non-nil, and an already-ended context prevents every check. Condition errors and context errors are returned unchanged. A running condition receives ctx and must observe it itself; WaitFor cannot interrupt the condition.

Discussed in Waiting and retrying

WaitForLine ( ctx : context.Context , t : testing.TB , pane : tmux.Pane , line : string )
function [source]
function [source]
WaitForLine

WaitForLine blocks until some line of the pane's screen is exactly line.

A pane that never shows line fails the test with the screen it last read.

WaitForScreen ( ctx : context.Context , t : testing.TB , pane : tmux.Pane , want : string , match : func(screen []string) bool )
function [source]
function [source]
WaitForScreen

WaitForScreen blocks until the pane's screen satisfies match.

want is the noun phrase used in the failure message.

match receives a newly read screen and must not retain it.

WaitForShellReady ( ctx : context.Context , t : testing.TB , pane : tmux.Pane )
function [source]
function [source]
WaitForShellReady

WaitForShellReady blocks until the pane first shows output. With ServerOptions.FixedShell , that expected first output is the harness prompt and serves as readiness evidence; custom shell startup output may not.

RunInPane calls it, and a test building its own pane should too.

WaitForText ( ctx : context.Context , t : testing.TB , pane : tmux.Pane , text : string )
function [source]
function [source]
WaitForText

WaitForText blocks until some line of the pane's screen contains text.

A pane that never shows text fails the test with the screen it last read.

Where ( values : []T , predicate : func(*T) bool ) []T
function [source]
function [source]
Where

Where returns a fresh slice of shallow copies for values accepted by predicate, retaining their source order. It evaluates every input value, so a no-match result is an empty slice.

Discussed in Filtering and querying, in practice

WhereSeq ( values : iter.Seq[T] , predicate : func(*T) bool ) iter.Seq[T]
function [source]
function [source]
WhereSeq

WhereSeq returns a lazy sequence of shallow copies for values accepted by predicate, retaining source order. It does not pull values until the result is iterated. When its consumer stops, WhereSeq stops pulling from values. For an infinite input, it runs until its consumer stops.

WindowActiveIs ( value : bool ) WindowFilter
function [source]
function [source]
WindowActiveIs

WindowActiveIs returns a WindowFilter that exactly matches the materialized active state from Window.Active. It sets no other criteria and does not validate value.

WindowFromEnv ( ctx : context.Context , environment : map[string]string ) (Window, error)
function [source]
function [source]
WindowFromEnv

WindowFromEnv returns the window containing the pane identified by the environment. Nil reads the process environment; a nonnil empty map does not.

Discussed in Environment

WindowIDIs ( value : WindowID ) WindowFilter
function [source]
function [source]
WindowIDIs

WindowIDIs returns a WindowFilter that exactly matches the stable tmux window identifier from Window.ID, including its @ sigil. It sets no other criteria and does not validate value.

WindowIndexIs ( value : int ) WindowFilter
function [source]
function [source]
WindowIndexIs

WindowIndexIs returns a WindowFilter that exactly matches the nonnegative winlink index from Window.Index. It sets no other criteria and does not validate value.

WindowNameIs ( value : string ) WindowFilter
function [source]
function [source]
WindowNameIs

WindowNameIs returns a WindowFilter that exactly matches the materialized window name from Window.Name. It sets no other criteria and does not validate value.

WindowRef ( id : WindowID ) Ref
function [source]
function [source]
WindowRef

WindowRef returns a selector-relative Ref addressing a window by ID, for a caller holding an identifier rather than a materialized record.

WindowSessionIDIs ( value : SessionID ) WindowFilter
function [source]
function [source]
WindowSessionIDIs

WindowSessionIDIs returns a WindowFilter that exactly matches the stable tmux session identifier from Window.SessionID, including its $ sigil. It sets no other criteria and does not validate value.

Esc

Type to search.