
Vscode Terminal Mcp
io.github.sirlordt由 GitHub 账号 sirlordt 发布v0.1.0更新于 Oct 24, 2026
Execute commands in visible VSCode terminal tabs with output capture and session reuse.
发布方自己的服务:Terminal Tax
概览
一个 MCP 服务器,在可见的 VS Code 终端标签页中执行命令,捕获输出并复用会话,让助手运行和监控 shell 命令。
- 可以做什么
- 在新建或复用的可见终端中运行命令,返回带退出码和耗时的干净输出;也可不等待地启动长时间命令,再用尾部模式增量轮询输出。创建、列出、按 agent 标签过滤并关闭终端会话,包括为并行子代理隔离的终端。向交互式终端发送文本,以回答提示、REPL 或确认。分页读取缓冲输出;超出限制的输出会保存为临时 JSON 文件并返回其路径。
- 适用场景
- 适合让助手执行构建、测试、安装或部署,并让用户在 VS Code 中实时观看进度;也适合驱动交互式命令行提示,并在多个步骤间保持持久的 shell 会话。
- 运行要求
- 通过 npx 从 npm 包 vscode-terminal-mcp 启动的本地进程;需要 Node.js 20+ 和 VS Code 1.93+,并安装配套扩展,因为命令经本地 IPC 套接字通过 VS Code Shell Integration API 执行。未声明账户、API 密钥或环境变量。
安装
在 SourceWeft 中
- 打开 控制台中的 Vscode Terminal Mcp,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
vscode-terminal-mcp
MCP server that executes commands in visible VSCode terminal tabs with full output capture. Unlike inline execution, every command runs in a real terminal you can see, scroll, and interact with.
Key Features
- Visible Terminals: Commands run in real VSCode terminal tabs, not hidden processes. You see everything in real time.
- Session Reuse: The
runtool automatically reuses idle sessions, creating new terminals only when needed. - Long-Running Support: Fire-and-forget execution with
waitForCompletion: false, then poll output incrementally withread. - Subagent Isolation: Tag sessions with
agentIdto keep parallel agent workloads separated.
Requirements
- VS Code 1.93+ (for Shell Integration API)
- Node.js 20+
Getting Started
Claude Code
VS Code / Copilot
Add to your .vscode/mcp.json:
Cursor
Add to your .cursor/mcp.json:
Claude Desktop
Add to your claude_desktop_config.json:
Your First Prompt
After installation, try asking:
Run
ls -lain the terminal
You should see a new terminal tab open in VSCode with the command output.
Screenshots
Running a command with run
Permission dialog for exec
Exec result with clean output
Tools
Quick Execution
Session Management
Usage Patterns
Simple Command
The run tool handles everything — creates a terminal if needed, executes, and returns clean output:
Long-Running Process
For builds, deployments, or any command that takes a while:
The agent will:
- Call
runwithwaitForCompletion: false— returns immediately - Call
readwithoffset: -10to check the last 10 lines - Repeat until the process completes
Interactive Commands
For commands that need user input:
The agent will:
- Call
runwithnpm init - Call
readto see the prompt - Call
inputto send the answer
Parallel Agents
Subagents can work in isolated terminals using agentId:
Each subagent gets its own terminal tagged with its agentId, preventing output from mixing.
Configuration
The extension reads configuration from VSCode settings under terminalMcp.*:
Recommended: Set as Preferred Tool
LLM agents like Claude Code have a built-in Bash tool that executes commands inline within the chat. The output is embedded in the conversation and hard to read, especially for commands with verbose output. We recommend telling the agent to prefer this MCP over its built-in Bash tool.
Add the following to your project's CLAUDE.md (or equivalent instructions file):
Why this matters:
Development: Updating the Extension
VSCode aggressively caches extensions in memory. When developing locally, code --install-extension and even "Developer: Reload Window" may not reload your changes. Use this workflow:
Quick update (no restart needed)
After modifying source files, build and copy directly into the installed extension directory:
Then run "Developer: Reload Window" (Ctrl+Shift+P).
Full reinstall (when quick update doesn't work)
If VSCode still uses old code:
Verify the correct version is loaded
Large Output Handling
When read returns output that exceeds the MCP client's token limit, the system automatically saves the full output to a temporary JSON file and returns the file path in the error message.
To extract the relevant content:
The file format is JSON: [{"type": "text", "text": "..."}]
This commonly happens with commands that produce heavy TUI output (progress bars, ANSI escape codes). Use smaller offset values (e.g., offset: -20 instead of offset: -100) to reduce the captured output size.
How It Works
- The VSCode extension activates and starts an IPC server on a Unix socket
- The MCP entry point (
mcp-entry.js) is spawned by the MCP client and bridges JSON-RPC stdio with the IPC socket - Commands execute in real VSCode terminals using the Shell Integration API for reliable output capture and exit code detection
- Output is stored in circular buffers with pagination support for efficient reading
Latest Changes (0.1.6)
- Screenshots in README for marketplace
- Clean output format for all tools — no more raw JSON
- Fixed
waitForCompletion: falsenot working - Disabled idle reaper — user closes sessions manually
- Unique IPC socket per workspace (multi-instance support)
- Custom terminal tab names with date format
- Large output handling documentation
See CHANGELOG.md for full history.
License
MIT
来源:README.md,提交 60df01d
工具
0版本历史
1- v0.1.0最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分
其他 Terminal 集成

Terminal Tax
tax.terminal官方发布者
托管式报税服务器:让助手提交美国联邦 2025 年个人报税表的事实,由服务计算并校验,再返回私人签署链接。
Terminal
mn.dta官方发布者
面向蒙古国宏观与市场数据档案的远程 MCP 服务器,让助手搜索序列、获取面板并核验带签名的观测数据。
SCRIPTMASTERLABS — Quant Terminal
com.scriptmasterlabs
远程 MCP 端点,提供基于真实数据的股票代码价位与“squeeze-mirror”预测,用于量化交易分析。

Terminal 7
由 GitHub 账号 LinkMarine777 发布
Solana 上 stonkfun 币的信号、评分和支付数据,供机器人和 AI 代理使用。AI 翻译
terminal-use
由 GitHub 账号 computer-agent-labs 发布
让 AI 助手操作本机真实终端会话:输入文字、按键、点击、读取屏幕并截图,包括全屏 TUI 程序。