Workspace ManagerCLI Manual

Choose documentation 3

latest

Current version

latest
English

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

Edit this page on GitHub

Evaluate in a workspace

LibTmux.Workspace 0.0.0-alpha.20 · Source

tmux-workspace shell opens the optional Python inspection environment for a loaded session. Code passed to -c executes in that environment, with tmux objects such as server, session, window and pane available.

Runtime requirement

Install tmuxp 1.74.0 in a separate Python environment and set TMUX_WORKSPACE_PYTHON to that environment’s Python executable. The native CLI checks the runtime before evaluating code. Ordinary workspace loading does not require this inspection runtime.

Evaluate with a selected server

Continue the installation walkthrough through its detached load. Select its socket, session and window:

Terminal window
$ tmux-workspace shell \
-S "$WORKSPACE_TMP/tmux.sock" \
-c 'print(pane.pane_id)' \
--json \
workspace-guide editor

The result includes captured output and child status. Check the command’s exit status before consuming it. An interactive shell needs a terminal; use -c when stdout belongs to automation.

shell --help lists backend and startup choices. Optional shell backends must be installed in the selected Python environment.

CLI source.

Esc

Type to search.