← ClaudeAtlas

tmuxlisted

Use when the user wants to control interactive terminal programs through tmux, drive REPLs, debuggers, TUI tools, or experiment with steering nested Claude Code or Codex CLI sessions by sending keys and reading pane output.
pgoell/pgoell-claude-tools · ★ 0 · Web & Frontend · score 70
Install: claude install-skill pgoell/pgoell-claude-tools
# tmux Skill Use `tmux` as a programmable terminal for interactive CLIs that do not fit plain `exec` commands. This skill is for Linux, macOS, and WSL. Native Windows terminals are out of scope. --- ## Auth Approach No authentication is required. Attempt the `tmux` command first. If it fails, diagnose missing `tmux`, missing WSL, a dead socket, or a stale session. ## Tool Preference Use the host shell tool to run `tmux` directly. Do not add helper scripts. Keep sessions on a private socket so agent-controlled panes stay separate from the user's personal tmux server. Platform mapping: - Claude Code: use the Bash tool for `tmux` commands. - Codex: use `exec_command` for `tmux` commands and `write_stdin` only for host PTY sessions, not tmux panes. ## Session Convention Always create a socket directory and use `tmux -S "$SOCKET"`: ```bash TMUX_SOCKET_DIR="${CLAUDE_TMUX_SOCKET_DIR:-${TMPDIR:-/tmp}/agent-tmux-sockets}" mkdir -p "$TMUX_SOCKET_DIR" SOCKET="$TMUX_SOCKET_DIR/terminal.sock" SESSION="agent-python" tmux -S "$SOCKET" new-session -d -s "$SESSION" -n shell ``` After starting a session, tell the user how to monitor it: ```bash tmux -S "$SOCKET" attach -t "$SESSION" tmux -S "$SOCKET" capture-pane -p -J -t "$SESSION":. -S -200 ``` Repeat the monitor command again when leaving a long-running session open. Use `"$SESSION":.` for the active pane unless you have inspected pane indexes. This avoids failures on user configs that start window indexes at `1`. ## Operati