agentleFS
KubementatKubementat/ai_agent_skills/skills/tmux-coder/SKILL.md

tmux-coder

Skill2 starsChanged 8 months agoMITView on GitHub

Spawn, monitor, and manage coding agents in tmux windows. Use to orchestrate parallel coding agents, check their status, detect stuck agents, and manage tmux sessions.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Resumption: Run tmux-list-sessions to find existing sessions, then use tmux-agent-status or tmux-ensure-progress

    line 82

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

/tmux-coder — Orchestrate Coding Agents via Tmux

You are an orchestration expert. Your job is to spawn, monitor, and manage coding agents running in separate tmux windows within a single session.

Trigger

User invokes /tmux-coder followed by their intent:

/tmux-coder start a new agent that reviews the files in src/
/tmux-coder what are my agents doing?
/tmux-coder ensure that the agents keep doing their task
/tmux-coder kill the current session
/tmux-coder list all active sessions

Core Workflows

1. Spawn a New Agent

./scripts/tmux-spawn-agent --session SESSION --agent AGENT --task "TASK_DESCRIPTION"
  • Adds a new window to the session with an auto-generated label (e.g., worker-1, reviewer-2)
  • Starts the specified agent binary in that window
  • Sends the task description via tmux send-keys
  • Injects "TASK_COMPLETE" as the finish-string instruction

2. List Active Sessions

./scripts/tmux-list-sessions [--all]
  • Lists tmux sessions managed by this skill
  • Without --all: shows only sessions tracked in ~/.tmux-coder/sessions.json
  • With --all: shows all tmux sessions on the default socket

3. Check Agent Status

./scripts/tmux-agent-status --session SESSION
  • Outputs structured status information

4. Ensure Progress (Background Watcher)

./scripts/tmux-ensure-progress --session SESSION --stuck-prompt "Please continue working autonomously"
  • Runs continuously in the background
  • Detects stuck agents (3 consecutive identical snapshots)
  • Sends recovery prompt to stuck agents
  • Exits when all agents report "TASK_COMPLETE"

5. Kill Session

./scripts/tmux-kill-session --session SESSION
  • Terminates the tmux session and all its windows

Session Management

  • Naming: User-provided or auto-generated (e.g., orchestration-20260417-143052)
  • Resumption: Run tmux-list-sessions to find existing sessions, then use tmux-agent-status or tmux-ensure-progress
  • Metadata: Stored in ~/.tmux-coder/sessions.json for tracking managed sessions

Supported Agents

  • pi — Pi coding agent
  • claude — Claude CLI
  • codex — Codex CLI
  • opencode — OpenCode CLI

Configuration

VariableDefaultDescription
TMUX_CODER_SOCKET_DIR${TMPDIR:-/tmp}/tmux-coder-socketsSocket directory
TMUX_CODER_STATE_DIR~/.tmux-coderSession metadata directory
STABLE_ROUNDS3Consecutive identical snapshots before declaring stuck
INTERVAL10Seconds between status checks
STUCK_PROMPT"Please continue working autonomously"Default recovery prompt

Reference Documents

TopicFile
Detailed script usage and examplesreferences/usage-guide.md
Script internals and error handlingreferences/script-internals.md

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.