Window.link
Link this window to another session via $ tmux link-window.
Source and package
-
Examples#
>>> w = session.new_window(window_name='link_test')>>> s2 = server.new_session(session_name='link_target')>>> w.link(s2)- Parameters
-
-
target_session(str | Session) # – Target session to link the window to. -
target_index(str | None) # – Target window index in the destination session. -
kill_existing(bool | None) # – Kill target window if it exists (-kflag). -
after(bool | None) # – Insert after the target window (-aflag). -
before(bool | None) # – Insert before the target window (-bflag). -
detach(bool | None) # – Do not make the linked window active (-dflag).
-
tmux command#
The tmux commands behind link.
tmux C API#
The C declarations in tmux that implement these commands.
In other ports#
Link a window into another session
| Language | Equivalent |
|---|---|
| Ruby | Lib |
| Lua | libtmux |
| Erlang | tmux |
| Haskell | No public Haskell equivalent is implemented; the current modules expose scalar values and version parsing. |
| TypeScript | window |
| Rust | window |
| Go | tmux |
| Java | io |
| C# | Lib |
| C++ | libtmux:: |
| Swift | Server |
| OCaml | Libtmux |
| Perl | Lib Explicit Server operation. Captured entities remain local observations; use a new snapshot to observe changes. |
No equivalent is recorded in PowerShell, Julia, Elixir, Common Lisp, Clojure, Kotlin, Scala or F#.