
nickgnd/tmux-mcp 是从 https://github.com/nickgnd/tmux-mcp. 导入的 MCP 服务器候选服务器。
概览
nickgnd/tmux-mcp 是从 https://github.com/nickgnd/tmux-mcp. 导入的 MCP 服务器候选服务器。
概述(AI 翻译)
模型上下文协议服务器,使Claude Desktop能够与TMUX会话内容交互和查看。这种集成使AI助手能够读取、控制并观察你的终端会话。
特色
- 列表和搜索 tmux 会话
- 查看并导航 TMMUX 窗口和窗格
- 从任意窗格捕获并暴露终端内容
- 在 tmux 面板中执行命令并检索结果(使用风险自负⚠️)
- 创建新的 tmux 会话和窗口
- 水平或垂直分割面板,尺寸可自定义
- 终止 tmux 会话、窗口和窗格
看看这段简短的视频,兴奋起来吧!
先修条件
- Node.js
- TMUX 安装并运行
用途
配置Claude桌面
将这台MCP服务器添加到您的Claude桌面配置中:
MCP服务器选项
你可以选择指定你正在使用的命令行 shell,如果未指定,默认为 bash
MCP服务器仅在执行命令时需要知道shell,以便正确读取其退出状态。
可用资源
tmux://sessions- 列出所有 tmux 会话tmux://pane/{paneId}- 查看特定 tmux 面板的内容
本页由 AI 翻译,技术细节请以原文为准。
README
Tmux MCP Server
Model Context Protocol server that enables Claude Desktop to interact with and view tmux session content. This integration allows AI assistants to read from, control, and observe your terminal sessions.
Features
- List and search tmux sessions
- View and navigate tmux windows and panes
- Capture and expose terminal content from any pane
- Execute commands in tmux panes and retrieve results (use it at your own risk ⚠️)
- Create new tmux sessions and windows
- Split panes horizontally or vertically with customizable sizes
- Kill tmux sessions, windows, and panes
Check out this short video to get excited!
Prerequisites
- Node.js
- tmux installed and running
Usage
Configure Claude Desktop
Add this MCP server to your Claude Desktop configuration:
"mcpServers": {
"tmux": {
"command": "npx",
"args": ["-y", "tmux-mcp"]
}
}
MCP server options
You can optionally specify the command line shell you are using, if unspecified it defaults to bash
"mcpServers": {
"tmux": {
"command": "npx",
"args": ["-y", "tmux-mcp", "--shell-type=fish"]
}
}
The MCP server needs to know the shell only when executing commands, to properly read its exit status.
Available Resources
tmux://sessions- List all tmux sessionstmux://pane/{paneId}- View content of a specific tmux panetmux://command/{commandId}/result- Results from executed commands
Available Tools
list-sessions- List all active tmux sessionsfind-session- Find a tmux session by namelist-windows- List windows in a tmux sessionlist-panes- List panes in a tmux windowcapture-pane- Capture content from a tmux panecreate-session- Create a new tmux sessioncreate-window- Create a new window in a tmux sessionsplit-pane- Split a tmux pane horizontally or vertically with optional sizekill-session- Kill a tmux session by IDkill-window- Kill a tmux window by IDkill-pane- Kill a tmux pane by IDexecute-command- Execute a command in a tmux paneget-command-result- Get the result of an executed command
安装
npx -y tmux-mcp配置
"mcpServers": {
"tmux": {
"command": "npx",
"args": ["-y", "tmux-mcp"]
}
}