Terminal.attach_current
Run an interactive terminal client until it exits. Select the exact session ID on the daemon currently listening at endpoint; this is explicitly unbound and accepts no captured target. No retry or daemon startup occurs. A successful result proves client exit, not continued attachment. Diagnostics go to stderr.
Source and package
- Qualified name
-
Libtmux_unix .Terminal. attach _current - Module
- Libtmux_unix
- Declared in
Terminal- Package
- libtmux-unix
- Source
- unix/libtmux_unix.mli
- val attach_current : ?cancel:Cancellation
.t -> ?cleanup:Cleanup.t -> ?binary:string -> ?read_only:bool -> ?update_environment:bool -> ?stdin:Unix.file_descr -> ?stdout:Unix.file_descr -> ?stderr:Unix.file_descr -> Libtmux.Endpoint -> session:Libtmux.t .Session -> (unit, Libtmux.Id .t .Error ) result.t -
Public owner:
Libtmux_unixDescription#
Descriptors default to the application's standard streams and remain caller-owned.
stdinmust be a terminal. Environment updates and read-only mode are disabled by default; inheritedTMUXandTMUX_PANEare removed. Cancellation terminates and reaps this terminal client, leaves the daemon running, then raisesCancellation.Cancelled. TERM gets 200 ms of cooperative grace before KILL and reaping. Scheduling and uninterruptible kernel work can add time. Supplycleanupbefore the call to retain secondary failures after cancellation.