Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

window.Window.linkedSessions

TypeScript

View as Markdown

Module
window
Declared in
Window
Package
libtmux
Source
packages/libtmux/src/window.ts
Other languages
Python Ruby Lua RustGo Java .NET C++ Swift
linkedSessions ( ) → Selection<Session>
method [source]
method [source]
linkedSessions

Every session this window is linked into.

In other ports Every session a window is linked into

Examples

window.linkedSessions.map((entry) => entry.name);

A window you just made belongs to the session you made it in:

>>> window = session.new_window(window_name="solo", attach=False)
>>> [s.session_name for s in window.linked_sessions] == [session.session_name]
True

Link it into a second session and it belongs to both:

>>> guest = server.new_session(session_name="guest")
>>> target = f"{guest.session_id}:"
>>> _ = server.cmd("link-window", "-d", "-s", window.window_id, "-t", target)
>>> sorted(s.session_name for s in window.linked_sessions) == sorted(
... [session.session_name, "guest"]
... )
True

0 declared, 0 inherited

Esc

Type to search.