
mcp server for unix pty control
@ianks
关于 mcp server for unix pty control
The native MCP server for Unix PTY control gives AI models authentic, low-latency terminal access by spawning true pseudo-terminals—not brittle AppleScript hacks—so you can open persistent Bash, Python, or SSH sessions, run commands like “ssh prod.server,” and stream only fresh o
基本信息
配置
使用下面的配置,将此服务器添加到你的 MCP 客户端。
{
"mcpServers": {
"terminal-mcp": {
"type": "stdio",
"command": "terminal-mcp"
}
}
}工具
7spawn a new terminal
run and get output immediately
start long-running commands
poll async command progress
see what's running
cleanup when done
ctrl-c and friends
概览
What is mcp server for unix pty control?
It is an MCP server that gives AI models real terminal access by spawning Unix pseudo-terminal sessions, running commands, and reading output. It is designed for developers who need native, low-latency shell interaction for AI agents.
How to use mcp server for unix pty control?
Install with cargo install --git https://github.com/ianks/terminal-mcp, then add to Claude Code using claude mcp add --scope user terminal-mcp. AI models can then call tools like create_session, execute_command, and list_sessions via JSON-RPC.
Key features of mcp server for unix pty control
- True Unix ptys, not AppleScript or workarounds
- Async I/O powered by Tokio
- Smart buffering that only returns new output
- Session persistence across tool calls
- Multi-session support to run several terminals at once
Use cases of mcp server for unix pty control
- AI-assisted remote server debugging via SSH
- Running long-lived shell commands with async output polling
- Automating multi-step development workflows (build, test, deploy)
- Interactive REPL sessions (Python, bash) controlled by an agent
- Switching between multiple terminal contexts in a single conversation
FAQ from mcp server for unix pty control
What tools does the server expose?
It provides create_session, execute_command, execute_command_async, read_streaming_output, list_sessions, destroy_session, and send_control_character.
How does it differ from script-based terminal access?
It uses real pseudo-terminals (ptys) rather than simulated or hacked I/O, giving proper shell interaction with features like ctrl-c, process groups, and terminal signaling.
Can I run multiple terminals at the same time?
Yes. The server supports multi-session management, allowing you to spawn several named sessions (e.g., bash, ssh, python) and switch between them.
How do I run a long-running command without blocking?
Use the execute_command_async tool to start the command, then poll progress with read_streaming_output until completion. Sessions stay alive between calls.
What runtime dependencies does it require?
A Unix-like system with Rust installed (to compile via Cargo) and support for Unix ptys. The server is compiled as a native binary and communicates over MCP (stdio transport by default).
开发工具 分类下的更多 MCP 服务器
Hello World MCP Server (Reference Extension)
anthropicsDesktop Extensions: One-click local MCP server installation in desktop apps
Serena
oraiosA powerful MCP toolkit for coding, providing semantic retrieval and editing capabilities - the IDE for your agent
Code Index MCP
johnhuang316A Model Context Protocol (MCP) server that helps large language models index, search, and analyze code repositories with minimal setup
sentry-mcp
getsentryAn MCP server for interacting with Sentry via LLMs.
MCP-Scan: An MCP Security Scanner
invariantlabs-aiSecurity scanner for AI agents, MCP servers and agent skills.
评论