On this page
tmux.Session.KillWith
- Module
- tmux
- Declared in
- Session
- Package
- github.com/libtmux/libtmux-go/tmux
- Source
- tmux/lifecycle_kill.go
- KillWith ( ctx : context.Context , request : SessionKillRequest ) error
-
KillWith applies one kill-session mode without refreshing the materialized receiver. The zero request destroys the receiver; AllExcept destroys every other session while preserving the receiver and its current window; ClearAlerts only clears alerts in windows linked to the receiver and leaves sessions, winlinks, panes, client attachments, and current-window selections unchanged. Destroying a session handles clients as
Session.Killdescribes and removes its winlinks; windows left without links and their panes are also destroyed. Group destroys the receiver's group and requires tmux 3.7; on older versions it followsUnsupportedPolicy.The three modes are mutually exclusive. Only stderr makes a completed command a
CommandError; nonzero exits without stderr are ignored. Transport errors are delivery-ambiguous.
0 declared, 0 inherited