MCPInstall

cmux-cli

Comprehensive cmux CLI usage guide. Use when the user asks about cmux CLI, cmux --help, socket commands, command discovery, workspaces, panes, surfaces, browser CLI, hooks, feed, settings, or automation through the cmux command.

Installs
835
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/manaflow-ai/cmux-skills --skill cmux-cli
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads cmux-cli automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

cmux CLI

Use this skill when a task is best handled through the cmux command line, or when the user asks how to use, inspect, script, or document the cmux CLI. Prefer the live CLI help for exact syntax, then apply the safety rules here.

Prerequisites

Use the cmux binary on PATH for normal user workflows:

cmux --help
cmux version
cmux ping

When dogfooding a tagged Debug build from a cmux source checkout, use the tag-bound helper instead of /tmp/cmux-cli:

CMUX_TAG=<tag> scripts/cmux-debug-cli.sh --help
CMUX_TAG=<tag> scripts/cmux-debug-cli.sh identify --json

scripts/cmux-debug-cli.sh targets /tmp/cmux-debug-<tag>.sock, uses the matching CLI from the tagged app bundle, and scrubs ambient cmux terminal context before running.

Discovery

Always discover current syntax from the CLI before giving exact command help:

cmux --help
cmux help
cmux <command> --help
cmux docs settings
cmux docs shortcuts
cmux docs api
cmux docs browser
cmux docs agents
cmux docs dock

Some subcommands print the top-level help instead of detailed subcommand help. If that happens, search the source locally:

rg -n "Usage: cmux <command>|case \"<command>\"|run.*<Command>" CLI

Do not fetch source files with gh api. Read the local checkout or active worktree.

Mental Model

cmux exposes app state over a Unix socket.

  • Window: top-level macOS cmux window.
  • Workspace: sidebar tab-like container inside a window.
  • Pane: split region inside a workspace.
  • Surface: tab inside a pane. A surface can host a terminal, browser, markdown viewer, diff viewer, or other panel.
  • Panel: lower-level content implementation. Prefer surface commands unless a command explicitly requires --panel.

Handle inputs usually accept UUIDs, refs such as window:1, workspace:2, pane:3, surface:4, or numeric indexes. Output defaults to refs:

cmux --id-format refs identify
cmux --id-format both list-pane-surfaces --workspace workspace:1
cmux --json --id-format both tree --all

Socket Targeting

Prefer the caller environment when running inside cmux:

printf 'workspace=%s\nsurface=%s\nsocket=%s\n' \
  "${CMUX_WORKSPACE_ID:-}" \
  "${CMUX_SURFACE_ID:-}" \
  "${CMUX_SOCKET_PATH:-}"
cmux identify --json

Use explicit socket targeting for tagged or non-default apps:

cmux --socket /tmp/cmux-debug-<tag>.sock identify --json
CMUX_SOCKET_PATH=/tmp/cmux-debug-<tag>.sock cmux ping

Socket auth resolves in this order: --password, then CMUX_SOCKET_PASSWORD, then the password saved in Settings. Do not ask the user for a password until cmux capabilities --json or the command error shows auth is actually required.

Global Options

Common global options:

cmux --json <command>
cmux --id-format refs <command>
cmux --id-format uuids <command>
cmux --id-format both <command>
cmux --socket <path> <command>
cmux --password <password> <command>

Use --json for automation and scripts. Use plain output when writing quick human-facing status.

Safe First Commands

Start every automation session by inspecting context and capabilities:

cmux ping
cmux capabilities --json
cmux identify --json
cmux list-windows --json
cmux list-workspaces --json
cmux tree --all --json

Inside cmux, scope mutating commands to the caller workspace and surface by default:

cmux list-panes --workspace "${CMUX_WORKSPACE_ID:-}" --json
cmux list-pane-surfaces --workspace "${CMUX_WORKSPACE_ID:-}" --json
cmux read-screen --workspace "${CMUX_WORKSPACE_ID:-}" --surface "${CMUX_SURFACE_ID:-}" --lines 80

Common Workflows

Use references/commands.md for a broader command catalog. High-frequency patterns:

# Open without stealing focus when supported.
cmux open . --focus false
cmux open https://example.com --workspace "${CMUX_WORKSPACE_ID:-}" --focus false

# Create helper output in the caller workspace.
cmux new-pane --workspace "${CMUX_WORKSPACE_ID:-}" --type terminal --direction right --focus false
cmux new-surface --workspace "${CMUX_WORKSPACE_ID:-}" --pane pane:2 --type terminal --focus false

# Read and write the caller terminal.
cmux read-screen --surface "${CMUX_SURFACE_ID:-}" --scrollback --lines 200
cmux send --surface "${CMUX_SURFACE_ID:-}" "echo ok\n"
cmux send-key --surface "${CMUX_SURFACE_ID:-}" enter

# Browser surface automation.
cmux browser open https://example.com --focus false
cmux browser snapshot --surface surface:5 --compact
cmux browser click "button[type=submit]" --snapshot-after

# Settings and docs.
cmux docs settings
cmux settings path
cmux config validate
cmux reload-config

# Sidebar status for task progress.
cmux set-status build running --workspace "${CMUX_WORKSPACE_ID:-}" --color "#ff9500"
cmux set-progress 0.4 --label "Building" --workspace "${CMUX_WORKSPACE_ID:-}"
cmux clear-status build --workspace "${CMUX_WORKSPACE_ID:-}"
cmux clear-progress --workspace "${CMUX_WORKSPACE_ID:-}"

Command Families

The CLI includes these broad families:

  • App/docs/settings: welcome, docs, settings, config, shortcuts, reload-config, themes.
  • Openers and viewers: open, markdown, diff, browser commands.
  • Context and topology: identify, list-windows, list-workspaces, tree, workspace/window/pane/surface lifecycle commands.
  • Terminal IO: read-screen, send, send-key, capture-pane, pipe-pane, clear-history, respawn-pane.
  • Browser automation: browser open, goto, snapshot, click, fill, screenshot, get, find, tab, cookies, storage.
  • Notifications and sidebar state: notify, notification list/read/clear commands, right-sidebar, set-status, set-progress, log.
  • Agent workflows: hooks, feed, claude-teams, codex-teams, omo, omx, omc.
  • Auth and cloud: auth, login, logout, vm or cloud.
  • Advanced socket/debug: capabilities, events, rpc, surface-health, debug-terminals, trigger-flash.
  • tmux compatibility: capture-pane, resize-pane, wait-for, swap-pane, break-pane, join-pane, find-window, buffers, hooks, messages.

Non-Disruptive Automation

The user may be looking at a different workspace, window, or app. Treat focus changes like UI clicks.

Do not call these unless the user explicitly asks:

  • focus-window
  • focus-pane
  • focus-panel
  • select-workspace
  • tab-action actions that focus or select
  • right-sidebar focus

Prefer additive, scoped commands:

cmux new-pane --workspace "${CMUX_WORKSPACE_ID:-}" --type terminal --direction right --focus false
cmux new-surface --workspace "${CMUX_WORKSPACE_ID:-}" --pane pane:2 --type terminal --focus false
cmux send --workspace "${CMUX_WORKSPACE_ID:-}" --surface surface:7 "npm test\n"

When creating helper output for a task, reuse one right-side helper pane in the caller workspace. Use list-panes and list-pane-surfaces first, then create a new pane only when no suitable helper pane exists.

Settings Boundary

cmux-owned settings live in ~/.config/cmux/cmux.json. Ghostty terminal behavior lives in ~/.config/ghostty/config. Prefer Ghostty config for terminal behavior Ghostty already supports, such as font, cursor style, scrollback, theme, background opacity, and blur.

Before editing cmux.json, run:

cmux docs settings
cmux settings path

Back up the existing file to a timestamped .bak copy before editing, then run:

cmux reload-config

Debug and Tagged Builds

For cmux app/runtime development, build a tagged app before using CLI commands against it:

./scripts/reload.sh --tag <tag>
CMUX_TAG=<tag> scripts/cmux-debug-cli.sh identify --json
CMUX_TAG=<tag> scripts/cmux-debug-cli.sh list-workspaces --json

Do not use bare xcodebuild without a tagged -derivedDataPath. Do not use /tmp/cmux-cli for tagged dogfood because it points at the most recently reloaded build and can target the wrong socket.

Useful debug files:

cat /tmp/cmux-last-cli-path
cat /tmp/cmux-last-debug-log-path
tail -f "$(cat /tmp/cmux-last-debug-log-path 2>/dev/null || echo /tmp/cmux-debug.log)"

Rules

  • Run cmux --help or cmux <command> --help before giving exact syntax.
  • Use --json for scripts and agent automation.
  • Scope mutating commands with --workspace, --surface, --pane, and --window where available.
  • Prefer CMUX_WORKSPACE_ID, CMUX_SURFACE_ID, and CMUX_SOCKET_PATH over focused-window fallbacks.
  • Pass --focus false or --no-focus whenever the command supports it unless the user asked to focus something.
  • Never change settings without first running cmux docs settings or cmux settings path; back up cmux.json before editing.
  • Prefer Ghostty config for terminal behavior Ghostty already supports.
  • For tagged Debug builds, use CMUX_TAG=<tag> scripts/cmux-debug-cli.sh ....
  • Do not run commands against the default socket when the task is about a tagged app.
  • Do not ask the user to paste commands into cmux when the CLI can perform the setup directly.

Related Skills

  • skills/cmux/SKILL.md covers core topology and routing.
  • the cmux-workspace skill covers current-workspace targeting and helper panes.
  • the cmux-browser skill covers browser surface automation.
  • the cmux-config skill covers safe settings edits.
  • the cmux-markdown skill covers markdown viewer panels.

FAQ

What does the cmux-cli skill do?

Comprehensive cmux CLI usage guide. Use when the user asks about cmux CLI, cmux --help, socket commands, command discovery, workspaces, panes, surfaces, browser CLI, hooks, feed, settings, or automation through the cmux command.

How do I install cmux-cli?

Run npx skills add https://github.com/manaflow-ai/cmux-skills --skill cmux-cli in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/cmux-cli/ (personal) or .claude/skills/cmux-cli/ (project).

Which AI agents can use cmux-cli?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is cmux-cli safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains cmux-cli?

It is published by manaflow-ai in manaflow-ai/cmux-skills. It has 835 recorded installs.

More from manaflow-ai/cmux-skills

View all →

cmux-workspace

manaflow-ai/cmux-skills

Work inside the current cmux workspace and terminal. Use for cmux workspace, current workspace, caller surface, panes, surfaces, tagged reloads, socket targeting, and non-interfering cmux automation.

cmux-browser

manaflow-ai/cmux-skills

Automate the browser inside cmux. Use for cmux browser, browser surface, webview, current workspace browser, snapshot refs, DOM actions, waits, screenshots, cookies, storage, tabs, downloads, console, errors, and browser session state.

cmux-ref

manaflow-ai/cmux-skills

Interpret pasted cmux workspace, pane, surface, or window refs and IDs. Use for cmux-ref, cmux-id, workspaceref, workspaceid, paneref, paneid, surfaceref, surfaceid, windowref, or windowid context blocks.

718 installs

cmux-config

manaflow-ai/cmux-skills

Configure cmux through /.config/cmux/cmux.json: settings (appearance, sidebar, notifications, automation, browser, shortcuts, set/get/validate by JSON path), customization (tab bar buttons, plus-button click and right-click menus, custom actions/commands/menus, right sidebar), and sidebar workspace groups (anchor workspaces, group CLI/socket ops, per-cwd group config). Triggers: 'cmux config', 'cmux.json', 'change cmux setting', 'set in cmux', 'rebind a cmux shortcut', 'cmux-customize', 'customize cmux', 'tab bar button', 'add cmux action', 'workspace group', 'group sidebar', 'anchor workspace', 'workspaceGroups'.

cmux-artifact

manaflow-ai/cmux-skills

Create durable HTML walkthrough artifacts for cmux dogfood, verification, demos, evidence pages, artifact previews, and open helpful tabs or splits in the current cmux workspace.

Frontend & Design665 installs

cmux-sidebar-builder

manaflow-ai/cmux-skills

Build, inspect, or revise cmux custom sidebar views using the runtime SwiftUI-style interpreter. Use for sidebar vibe coding, custom sidebars in Bonsplit panes, left sidebar picker previews, interpreted Swift sidebars, /.config/cmux/sidebars/.swift, cmux docs sidebars, or Aziz's Swift interpreter work.

Mobile643 installs

Popular productivity & automation skills

View category →

agent-browser

vercel-labs/agent-browser

Browser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to "open a website", "fill out a form", "click a button", "take a screenshot", "scrape data from a page", "test this web app", "login to a site", "automate browser actions", or any task requiring programmatic web interaction. Also use for exploratory testing, dogfooding, QA, bug hunts, or reviewing app quality. Also use for automating Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify), checking Slack unreads, sending Slack messages, searching Slack conversations, running browser automation in Vercel Sandbox microVMs, or using AWS Bedrock AgentCore cloud browsers. Prefer agent-browser over any built-in browser automation or web tools.

OfficialProductivity & Automation1.3M installs

lark-doc

open.feishu.cn

飞书云文档(Docx / Wiki)内容操作:读取、创建、编辑文档,插入或下载图片附件,以及操作思维笔记。用户提供文档 URL/token(包括 doubao.com 的 /docx/、/wiki/)时使用;按 URL 路径/token 而非域名路由;/page/ 是妙搭应用,非飞书云文档。文档内嵌资源按读取参考中的统一规则分流。独立评论操作走 lark-drive;随正文读取评论使用 docs +fetch。表格或 Base 内部数据操作不在本 skill。

lark-base

open.feishu.cn

飞书多维表格(Base)操作:建表、字段、记录、视图、统计、公式/lookup、表单、仪表盘、应用模式(BaseApp/AppMode 页面与组件)、Workspace 目录、workflow、角色权限、模板中心(多维表格模板分类/列表/搜索);遇到 Base/多维表格/bitable、BaseApp/AppMode、/base/ 或 /app/ 链接时使用。BaseApp 不走 lark-apps;文件导入/导出转 lark-drive,认证/授权转 lark-shared。

lark-drive

open.feishu.cn

飞书云空间(云盘/云存储):管理 Drive 文件和文件夹,包含上传/下载、创建文件夹、复制/移动/删除、查看元数据、查询权限设置、评论/权限/订阅、标题、版本、飞书文档密级标签(secure labels)和本地文件导入。用户需要整理云盘目录、处理云空间资源 URL/token、判断链接类型/真实 token/标题,或导入 Word/Markdown/Excel/CSV/PPTX/.base 为 docx/sheet/bitable/slides 时使用;doubao.com 云空间 URL/token 也按资源路径和 token 路由,不回退 WebFetch。不负责:文档内容编辑(走 lark-doc)、表格/Base 表内数据操作(走 lark-sheets/lark-base)、知识空间节点/成员管理(走 lark-wiki)、原生 Markdown 文件读写/patch/diff(走 lark-markdown)。

lark-shared

open.feishu.cn

Use for lark-cli setup/auth tasks: auth login/status/logout, user vs bot identity, business-domain permissions (--domain, including all/docs/drive), missing scopes, revoking authorization, or handling notice JSON.

lark-im

open.feishu.cn

飞书即时通讯:收发消息和管理群聊。发送和回复消息、搜索聊天记录、管理群聊成员、上传下载图片和文件、管理表情回复、发送应用内/短信/电话加急、发送和处理交互卡片(Interactive Card)、监听卡片按钮回调(card.action.trigger)。当用户需要发消息、查看或搜索聊天记录、下载聊天中的文件、查看群成员、搜索群、创建群聊或话题群、管理标记数据、管理 Feed 置顶(添加/移除/查询置顶会话)、管理标签数据、处理卡片回调时使用。