Badge & Role Demo¶
A showcase of the custom Sphinx roles and visual elements available in libtmux-mcp documentation.
Toolset badges¶
Standalone badges via {badge}:
inspect — read tmux state and terminal output
manage — change tmux structure or presentation
execute — start or drive pane processes
teardown — delete tmux objects or retained scrollback
Tool references¶
{tool} — code-linked with badge¶
capture_pane inspect · capture_since inspect · send_keys execute · search_panes inspect · wait_for_text inspect · kill_pane teardown · create_session execute · split_window execute
{toolref} — code-linked, no badge¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
{tooliconl} — icon left, outside code¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
{tooliconr} — icon right, outside code¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
{tooliconil} — icon inline-left, inside code¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
{tooliconir} — icon inline-right, inside code¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
{ref} — plain text link¶
capture_pane · capture_since · send_keys · search_panes · wait_for_text · kill_pane · create_session · split_window
Badges in context¶
In a heading¶
These are the actual tool headings as they render on tool pages:
capture_paneinspect
split_windowexecute
kill_sessionteardown
In a table¶
Tool |
Toolset |
Description |
|---|---|---|
inspect |
List all sessions |
|
execute |
Send input to a pane |
|
teardown |
Delete a pane |
In prose¶
Use search_panes to find text across all panes. If you know which pane, use capture_pane for one read or capture_since for repeated observation. For authored shell commands, use run_command instead of manually sending, waiting, and capturing.
Dense inline (toolref, no badges)¶
The fundamental command pattern: run_command → inspect exit_status and output. For discovery: list_sessions → list_panes → get_pane_info.
Environment variable references¶
LIBTMUX_SOCKET · LIBTMUX_TOOLSETS · LIBTMUX_SOCKET_PATH · LIBTMUX_TMUX_BIN
Glossary terms¶
Admonitions¶
Tip
Use search_panes before capture_pane when you don’t know which pane has the output you need.
Warning
Do not call capture_pane immediately after send_keys — there is a race condition. Use run_command for authored commands, or capture_since when input and later observation are intentionally separate.
Note
Targeted tools accept an optional socket_name parameter for multi-server support.
Badge anatomy¶
Each badge renders as:
<span class="sd-badge sd-bg-success"
role="note"
aria-label="Toolset: inspect">
🔍 inspect
</span>
Features:
Emoji icon — 🔍 inspect, 🔧 manage, ✏️ execute, 💣 teardown (native system emoji, no filters)
Matte colors — forest green, blue, smoky amber, matte crimson with 1px border
Accessible —
role="note"+aria-labelfor screen readersNon-selectable —
user-select: noneso copying tool names skips badge textContext-aware sizing — slightly larger in headings, smaller inline
Sidebar compression — badges collapse to colored dots in the right-side TOC
Heading flex —
h2/h3/h4:has(.sd-badge)centers badge against cap-height