cli-tmux

cli-tmux is a skill for Claude Code from nibzard/skills. It costs 40 tokens per session (770 once invoked), scanned A, original, MIT.

A procedure for running and testing an interactive command-line program in tmux, a terminal tool that keeps processes running in separate sessions.

In plain words
What is it for?
Use it for interactive command-line interfaces, terminal user interfaces, prompts, keyboard navigation, and long-running development servers.
Why use it?
It provides a repeatable way to send keys, capture screen output, test real terminal behavior, and clean up the session afterward.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the tmux plugin — 1 skill shipped together

Good fit Use it for interactive command-line interfaces, terminal user interfaces, prompts, keyboard navigation, and long-running development servers.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nibzard/skills/tmux
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add nibzard/skills --skill tmux
Clone the repo
git clone --depth 1 https://github.com/nibzard/skills

Made for: Claude Code.

Or install tmux, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cli-tmux

README.md
[![agentmods](https://agentmods.dev/badge/skills/nibzard/skills/tmux/github.svg)](https://agentmods.dev/skills/nibzard/skills/tmux)
Your own site
<a href="https://agentmods.dev/skills/nibzard/skills/tmux"><img src="https://agentmods.dev/badge/skills/nibzard/skills/tmux/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for cli-tmux

Your own site · 80×15
<a href="https://agentmods.dev/skills/nibzard/skills/tmux"><img src="https://agentmods.dev/badge/skills/nibzard/skills/tmux.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 770 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00040 $0.00770
Opus 5 $0.00020 $0.00385
Sonnet 5 $0.00008 $0.00154
Haiku 4.5 $0.00004 $0.00077

Measured 9d ago against content hash 3941bee01b05, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

cli-tmux scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/tmux/skills/tmux/SKILL.md · 71 lines

How it starts

The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.

cli-tmux skill: run & test the CLI using tmux

Use this skill when

  • The user asks to test the CLI end-to-end and it is interactive (TUI prompts, key navigation).
  • A command needs a real TTY or long-running process (dev server) that should keep running while we do other tasks.

Golden rules

  1. Prefer scripts/tmuxctl.sh over raw tmux commands for repeatability.
  2. Use an isolated tmux server socket so we don't interfere with the user's real tmux sessions.
  3. Use a predictable session name: agent-cli.
  4. Always capture pane output after each interaction and summarize it before proceeding.
  5. Always clean up: stop the TUI and kill the session at the end (unless the user wants it left running).

tmuxctl.sh wrapper (preferred)

Prefer scripts/tmuxctl.sh over raw tmux commands for repeatability:

  • scripts/tmuxctl.sh start - Create new tmux session
  • scripts/tmuxctl.sh run ./bin/ourcli - Run command in the session
  • scripts/tmuxctl.sh keys Down Down C-m - Send keystrokes
  • scripts/tmuxctl.sh capture - Capture pane output
  • scripts/tmuxctl.sh stop - Stop the TUI (double Ctrl+C)
  • scripts/tmuxctl.sh kill - Kill the session

Our CLI/TUI specifics

  • To exit the TUI, send double Ctrl+C: C-c then C-c.
  • If double Ctrl+C doesn't exit, fallback to killing the tmux pane/session.

Standard tmux setup (isolated socket)

  • Socket path: .tmp/tmux-agent.sock
  • Session: agent-cli
  • Pane target: agent-cli:0.0

Create session (if missing)

  • Ensure .tmp/ exists.
  • Start detached session in repo root:
    • tmux -S .tmp/tmux-agent.sock new-session -d -s agent-cli -c "$PWD"

Start the CLI

  • Send the run command (replace with our real command):
    • Example: ./bin/ourcli OR pnpm ourcli OR go run ./cmd/ourcli
  • Use:
    • tmux -S .tmp/tmux-agent.sock send-keys -t agent-cli:0.0 "<COMMAND HERE>" C-m

Interact

  • Send keys as needed:
    • Enter: C-m
    • Up/Down: Up / Down
    • Quit: C-c C-c (double)

Capture output (after each step)

  • tmux -S .tmp/tmux-agent.sock capture-pane -t agent-cli:0.0 -p

Read the full file on GitHub · 71 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 71 lines · 40 tokens per session scan A 3941bee01b05

Subscribe to this mod's changes

cli-tmux is a skill published in the GitHub repository nibzard/skills (2 stars, last pushed 1mo ago), licensed MIT. It adds 40 tokens to every session and 770 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

skillshare-cli-e2e-test

Run isolated E2E tests in devcontainer from aidocs/tests runbooks. Use this skill whenever the user asks to: run an E2E test, execute a test runbook, validate a feature end-to-end, create a new runbook, or test CLI behavior in isolation. If you need to run a multi-step CLI validation sequence (init → install → sync →…

runkids/skillshare · 127 tokens

e2e-testing

Guide for running end-to-end tests of the Qwen Code CLI, including headless mode, MCP server testing, and API traffic inspection. Use this skill whenever you need to verify CLI behavior with real model calls, reproduce user-reported bugs end-to-end, test MCP tool integrations, or inspect raw API request/response…

QwenLM/qwen-code · 94 tokens

terminal-capture

Automates terminal UI screenshot testing for CLI commands. Applies when reviewing PRs that affect CLI output, testing slash commands (/about, /context, /auth, /export), generating visual documentation, or when 'terminal screenshot', 'CLI test', 'visual test', or 'terminal-capture' is mentioned.

QwenLM/qwen-code · 66 tokens

agent-reproduce-align

Use after a Codex or Claude Code feature has been implemented in Qwen Code to run the selected reference agent and Qwen Code under the same scenario, capture HTTP and terminal traces, compare request bodies, tool/function schemas, outputs, and iterate until the reproduced behavior is close enough.

QwenLM/qwen-code · 62 tokens

verify

Exercise the real app/API/CLI and collect observable evidence; tests alone do not count as end-to-end verification.

Hmbown/CodeWhale · 25 tokens

webapp-testing

Start/reuse a local app, wait for readiness, inspect rendered state/console/network, act from observed selectors, and verify with evidence.

Hmbown/CodeWhale · 32 tokens