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

View as Markdown

Module
libtmux
Package
libtmux-cxx
Source
include/libtmux/server.hpp
Other languages
PythonRubyLuaTypeScriptRustGoJava.NETSwift
class libtmux::Server
class [source]
class [source]
class libtmux::Server

One tmux server, addressed by the socket it listens on.

The entry point: sessions, windows and panes are read from here and carry the server with them. Constructing a handle sends no command. Only a startable handle may create an absent daemon; ordinary handles never do.

Discussed in Attaching to tmux · C++ MCP API , C++ workspace internals , C++ workspace builder examples , Develop the C++ workspace consumer , C++ workspace builder behavior · Architecture , Options and hooks

In other ports A tmux server

56 declared, 0 inherited

Members

  • sessions method One snapshot each.
  • windows method tmux scopes window and pane listings to the current session unless asked for every one, so -a is part of the request rather than a caller's responsibility to remember.
  • panes method
  • clients method
  • buffers method The server's cut buffers, newest first as tmux orders them.
  • commands method Every command this tmux understands, with its alias and usage.
  • new_session method Created detached, and returned, because tmux prints what it made.
  • source_file method Run the commands in a file, the way tmux runs a configuration file.
  • kill method End the server and everything in it.
  • options method
  • hooks method
  • set_buffer method Put text in a named buffer, replacing what was there.
  • is_alive method Whether a server is answering on this socket.
  • run_shell method Run a shell command on the machine the server is on.
  • set_server_option method
  • wait_for method Block until someone signals this channel, or the deadline passes.
  • load_buffer method Read a file into a named buffer, and write one back out.
  • save_buffer method
  • bind_key method Bind a key in a key table, and take a binding away again.
  • unbind_key method Unbinding a key that was not bound succeeds; unbinding in a table that does not exist is refused.
  • session method One object by target, for a caller holding an id or a session:window path that came from somewhere else.
  • window method
  • pane method
  • show_message method Put a message on the status line of every attached client, and send it to each control client as message.
  • run_chain method Run a chain.
  • from_env method The server this process is running inside.
  • global_options method
  • set_global_option method Sets the value every session inherits, rather than one session's own.
  • remove_environment method Keep the name and take it out of what a new process inherits — tmux's -r, which a listing then prints as -NAME.
  • unset_environment method Forget the name, so a new process inherits whatever the tmux server itself has.
  • at_default method The server tmux would talk to with no -L or -S at all, which is the one a person means when they say "my tmux".
  • at_socket_name method -L name: resolved under tmux's socket directory, as the tmux flag does.
  • at_socket_path method -S path: the socket file, used verbatim.
  • control method Open a control-mode connection to one session.
  • global_hooks method A hook set globally is not reported by the unscoped listing, so reading it back needs the scope it was set with.
  • signal method Release whoever is waiting on the channel, or latch it for whoever waits next.
  • capabilities method The local backend contract; no command runs.
  • check_alive method The same question, keeping why the answer was no.
  • check_file method Parse the same file and report what tmux would refuse in it, running none of it.
  • control_with_options method The Server supplies the socket and session supplies the session name; every other connection option is kept, including pane output policy.
  • environment method The environment every new process on this server starts with.
  • expand method Ask tmux to expand a format, against no target but the server itself.
  • over method A Server over a transport the caller supplies.
  • over_control method A Server whose commands travel over held-open control clients attached to session , rather than one launched process each.
  • run method Run one command and return its standard output.
  • run_batch method Run several commands in one invocation.
  • server_options method The server's own options, which are neither session nor window options and are the only ones a server without a session still has.
  • set_environment method Bind a name.
  • set_global_hook method
  • socket_path method The resolved path pinned by this handle, including a startable path whose server has not been created yet.
  • startable_at_default method
  • startable_at_socket_name method
  • startable_at_socket_path method A socket handle that may create an absent server on its first new_session call or an explicit run({"start-server"}).
  • tmux_version method Ask the selected subprocess executable with tmux -V without touching a server.
  • try_submit method Admit one command to an explicit bounded runtime without waiting for it.
  • wait_for_text method Wait until the pane target names produces wanted.
Esc

Type to search.