Session
Starts queries confined to one session.
Source and package
- Qualified name
-
LibTmux .FSharp. Session - Namespace
- LibTmux.FSharp
- Package
- LibTmux.FSharp
- Source
- src/LibTmux.FSharp/Hierarchy.fsi
-
Description
Each function takes the session it acts on last. One that runs a tmux command also takes the cancellation token first and returns a
Task. The session is the coreLibTmux.Sessionhandle, which is immutable and safe to share.What is on here
A tmux session has a good many members, but this module covers the part an F# caller reaches first. The rest lives on the core handle. The members fall into a few groups:
- Looking inside
- Start a query over the session's windows or panes; either throws
IncompleteSnapshotExceptionwhen the session was not read through a server. Or ask tmux now for the pane the session shows, its current window's active pane, which throwsTmuxObjectNotFoundExceptionwhen tmux reports none. - Changing the session
- Renaming returns a handle carrying the new name, and tmux expands the name as a format, so a
#in it does not survive verbatim. Killing the session takes its windows and panes with it, and leaves off the core's other kill options. Creating a window returns it as the request describes, and cancellation can leave the window created. - Waiting
- Each wait on the session's panes attaches a control client and lets it go when the wait ends. Holding one across a series of waits saves that attach for each, until the handle is disposed; use it with
use!.
The rest of a session is on the core
LibTmux.Session, which F# calls like any .NET type: selecting and stopping windows, locking, attaching and detaching clients, and the session's options, hooks, and environment.Optionsreads and writes an option through the options of that scope.
Members7 members
Collections and queries2
Common operations3
- activePane Reads from tmux the pane the session shows: its current window's active pane.
- holdWaitClient Keeps the control client that waits on the session's panes use attached until the handle is disposed.
- newWindow Creates a window in the session as the request describes, and returns it.
Other members2
Guides
task materialPages that discuss Session.
In other ports
task equivalence 22 other ports mappedSource-verified mappings for A tmux session. A mapping says these APIs perform the same task. It does not say they share defaults, errors or completion: check each page.
| Port | API | Differs from F# |
|---|---|---|
| F# | Lib Starts queries confined to one session. | This page |
| Python | libtmux tmux(1) Session [session_manual]. | None recorded in the model |
| Ruby | Lib | None recorded in the model |
| Lua | libtmux | None recorded in the model |
| PowerShell | Lib Read sessions with optional exact selectors. | This cmdlet reads and returns shared .NET LibTmux.Session objects. Child windows and panes require further acquisition. |
| Julia | Lib | 2 overloads SessionSnapshot holds captured session data. Actions use its SessionRef, a typed identity bound to an observed daemon generation. |
| Erlang | #tmux | None recorded in the model |
| Elixir | Lib An immutable session observation. Attachment retains tmux's client count. | Session is an immutable observation. Fields not captured read as :unloaded. |
| Haskell | Lib Detached physical session. Navigate its appearances through WindowLink. | Session is a detached physical session. WindowLink records each placement of a window in it, and operations take a generation-bound SessionRef. |
| Common Lisp | libtmux: A captured physical tmux session. | session is an immutable captured entity. The same name also has a relation accessor with a distinct public identity. |
| TypeScript | session One session on one tmux server, as a handle rather than a copy of it. | None recorded in the model |
| Rust | session One tmux session, together with the snapshot it was discovered with. | None recorded in the model |
| Go | tmux Session is one materialized tmux session record. It is normally returned by Server.Snapshot, Server.Session, or Session.Refresh. A zero Session is not a usable tmux target. | None recorded in the model |
| Java | io One tmux session, as one capture saw it. | readonly |
| Clojure | libtmux Acquires captured sessions; acquisition failure throws. | Acquires a vector of captured session maps. The session value is a map, not a wrapper class. |
| Kotlin | io A tmux session and its captured windows and properties. | None recorded in the model |
| Scala | io A captured session, opaque over the Java handle; every operation beyond equality is an extension, generated from the operation catalog or handwritten where the catalog marks it WAIT, STREAM or LIFECYCLE. | 2 overloads |
| C# | Lib Represents an immutable session handle and snapshot. | None recorded in the model |
| C++ | libtmux:: One session, as one listing saw it. | None recorded in the model |
| Swift | Session A tmux session, as it was when the listing was read. | None recorded in the model |
| OCaml | Libtmux | None recorded in the model |
| Perl | Lib Captured session entity | A captured read-only entity; explicit Server operations accept its stable identity. |
| Raku | Lib Captured session with local window-link and group relationships. | None recorded in the model |