tmux
Makes your agent master the terminal with tmux. It manages sessions, windows, and panes to organize your work. Ideal for those who work heavily in the terminal and want more efficiency.
What it does
tmux is a tool that lets you organize and keep multiple windows and splits (called 'panes') within a single terminal. It's useful for keeping your work active even if you disconnect from a remote server.
When to use it
- ✓When you need to keep a job running on a server even after disconnecting.
- ✓When you want to organize your work into multiple 'screens' (windows) or splits within the terminal.
- ✓When you want to automate repetitive terminal tasks using scripts.
Example of what to ask your AI
“How do I create a session named 'my-work' that keeps running even if I disconnect?”
Want more? Open the sections below.
How to use
The easiest way: copy the message below and paste it into Claude, ChatGPT, Cursor or any AI. It reads the skill and follows the instructions.
Skill link
Ready-to-paste message
How it works
tmux organizes work into sessions, windows (like tabs), and panes (screen splits). You can control everything via terminal commands or keyboard shortcuts.
Installation
Easiest way: copy the skill link and paste it into Claude, ChatGPT or Cursor asking it to follow the instructions.
In the terminal (Claude Code, Codex, Cursor), in your project folder:
npx skills add sickn33/agentic-awesome-skills --skill tmuxOr download just the file:
curl -L https://raw.githubusercontent.com/sickn33/agentic-awesome-skills/main/plugins/agentic-awesome-skills-claude/skills/tmux/SKILL.md -o SKILL.mdTechnical content (original SKILL.md)
Original text by the author, straight from GitHub.
tmux — Terminal Multiplexer
Overview
tmux keeps terminal sessions alive across SSH disconnects, splits work across multiple panes, and enables fully scriptable terminal automation. This skill covers session management, window/pane layout, keybinding patterns, and using tmux non-interactively from shell scripts — essential for remote servers, long-running jobs, and automated workflows.
When to Use This Skill
- Use when setting up or managing persistent terminal sessions on remote servers
- Use when the user needs to run long-running processes that survive SSH disconnects
- Use when scripting multi-pane terminal layouts (e.g., logs + shell + editor)
- Use when automating
tmuxcommands from bash scripts without user interaction
How It Works
tmux has three hierarchy levels: sessions (top level, survives disconnects), windows (tabs within a session), and panes (splits within a window). Everything is controllable from outside via tmux <command> or from inside via the prefix key (Ctrl-b by default).
Session Management
# Create a new named session
tmux new-session -s work
# Create detached (background) session
tmux new-session -d -s work
# Create detached session and start a command
tmux new-session -d -s build -x 220 -y 50 "make all"
# Attach to a session
tmux attach -t work
tmux attach # attaches to most recent session
# List all sessions
tmux list-sessions
tmux ls
# Detach from inside tmux
# Prefix + d (Ctrl-b d)
# Kill a session
tmux kill-session -t work
# Kill all sessions except the current one
tmux kill-session -a
# Rename a session from outside
tmux rename-session -t old-name new-name
# Switch to another session from outside
tmux switch-client -t other-session
# Check if a session exists (useful in scripts)
tmux has-session -t work 2>/dev/null && echo "exists"
Window Management
# Create a new window in the current session
tmux new-window -t work -n "logs"
# Create a window running a specific command
tmux new-window -t work:3 -n "server" "python -m http.server 8080"
# List windows
tmux list-windows -t work
# Select (switch to) a window
tmux select-window -t work:logs
tmux select-window -t work:2 # by index
# Rename a window
tmux rename-window -t work:2 "editor"
# Kill a window
tmux kill-window -t work:logs
# Move window to a new index
tmux move-window -s work:3 -t work:1
# From inside tmux:
# Prefix + c — new window
# Prefix + , — rename window
# Prefix + & — kill window
# Prefix + n/p — next/previous window
# Prefix + 0-9 — switch to window by number
Pane Management
# Split pane vertically (left/right)
tmux split-window -h -t work:1
# Split pane horizontally (top/bottom)
tmux split-window -v -t work:1
# Split and run a command
tmux split-window -h -t work:1 "tail -f /var/log/syslog"
# Select a pane by index
tmux select-pane -t work:1.0
# Resize panes
tmux resize-pane -t work:1.0 -R 20 # expand right by 20 cols
tmux resize-pane -t work:1.0 -D 10 # shrink down by 10 rows
tmux resize-pane -Z # toggle zoom (fullscreen)
# Swap panes
tmux swap-pane -s work:1.0 -t work:1.1
# Kill a pane
tmux kill-pane -t work:1.1
# From inside tmux:
# Prefix + % — split vertical
# Prefix + " — split horizontal
# Prefix + arrow — navigate panes
# Prefix + z — zoom/unzoom current pane
# Prefix + x — kill pane
# Prefix + {/} — swap pane with previous/next
Sending Commands to Panes Without Being Attached
# Send a command to a specific pane and press Enter
tmux send-keys -t work:1.0 "ls -la" Enter
# Run a command in a background pane without attaching
tmux send-keys -t work:editor "vim src/main.py" Enter
# Send Ctrl+C to stop a running process
tmux send-keys -t work:1.0 C-c
# Send text without pressing Enter (useful for pre-filling prompts)
tmux send-keys -t work:1.0 "git commit -m '"
# Clear a pane
tmux send-keys -t work:1.0 "clear" Enter
# Check what's in a pane (capture its output)
tmux capture-pane -t work:1.0 -p
tmux capture-pane -t work:1.0 -p | grep "ERROR"
Scripting a Full Workspace Layout
This is the most powerful pattern: create a fully configured multi-pane workspace from a single script.
#!/usr/bin/env bash
set -euo pipefail
SESSION="dev"
# Bail if session already exists
tmux has-session -t "$SESSION" 2>/dev/null && {
echo "Session $SESSION already exists. Attaching..."
tmux attach -t "$SESSION"
…
FAQ
What happens if my internet connection drops?
With tmux, your work session continues running on the server. You can reconnect and pick up where you left off.
How do I see all my active sessions?
You can use the command `tmux ls` to list all running sessions.
How do I exit a session without closing it?
Inside tmux, you press the prefix key (usually Ctrl+b) followed by the letter 'd' (for detach) to exit without ending the session.
Details
Original description by the author
Expert tmux session, window, and pane management for terminal multiplexing, persistent remote workflows, and shell scripting automation.
Popularity
- GitHub stars
- 48k
- Ranking position
- #4384
- License
- MIT
- Updated
- 10/15/2026
Comments
- …
More skills from this repository
00-andruia-consultant
Helps your agent start or improve AI projects. It analyzes code, suggests tools, and creates action plans in Spanish.
sickn33/agentic-awesome-skills
007
Lets your agent perform security audits and threat modeling. It's useful for protecting projects against attacks and vulnerabilities.
sickn33/agentic-awesome-skills
10-andruia-skill-smith
Helps your agent create or improve AI tools. It defines how tools work, writes documentation, and validates the structure.
sickn33/agentic-awesome-skills
20-andruia-niche-intelligence
Lets your agent create a summary about a specific industry. It's useful for understanding the context, rules, usage patterns, and risks of a project, using reliable sources.
sickn33/agentic-awesome-skills
Similar skills
bun-runtime
Has your agent use Bun to run, organize, and test code. It helps choose Bun over other tools and migrate existing projects.
affaan-m/ECC
database-migrations
Helps your agent make safe changes to databases. It ensures changes can be undone and minimizes downtime.
affaan-m/ECC
deployment-patterns
Sets up deployment and CI/CD workflows, containerization, and rollback strategies to ensure safe releases.
affaan-m/ECC