Server.WaitForAsync
Waits on, signals, locks, or unlocks a tmux channel.
Source and package
- WaitForAsync ( request : Wait
For , cancellationToken : CancellationRequest Token ) Task -
Description#
Waiting blocks until something else signals the channel, so a call that waits does not return on its own. A wait or a lock is not bounded by
CommandTimeout: it waits for another client by design, and ending it would leave tmux holding its place.- Parameters
-
-
request ( Wait
For ) – Which channel, and what to do with it.Request -
cancellationToken ( Cancellation
Token ) – Cancels waiting for tmux's reply. ForWaitthis kills the client, and tmux before 3.8 keeps its queue entry, which takes the next signal: a signal sent while nothing else waits is then spent on that entry instead of waking the next wait. PreferOpenWaitChannelwhenever aWaitneeds a deadline. ForLockcancelling never kills the client, since tmux hands a released lock to whichever queued client is still alive: the client keeps running, and a lock it goes on to acquire is released again automatically once this call has already given up on it. A lock that is never released therefore keeps one tmux client queued per cancelled call.
-
tmux command
wait-forIn other ports Wait for, signal or lock a channel
- Python
libtmux.Server.wait_for - Ruby
LibTmux::Server#wait_for - Lua No source-verified Lua equivalent is recorded for this operation.
- TypeScript no equivalent on
Server - Rust
server.Server.wait_for_channel - Go
tmux.Server.WaitFor - Java no equivalent on
Server - C++
libtmux::Server::wait_for - Swift
Server.wait(for:) - Kotlin No source-verified Kotlin equivalent is recorded for this operation.
- Scala No source-verified Scala equivalent is recorded for this operation.
- F# No source-verified F# equivalent is recorded for this operation.