Skip to content

Commit efe45da

Browse files
committed
docs: Add MCP clients configuration page
why: Client configuration is a gate — users who can't wire the server into their client don't proceed. Deserves its own focused page. what: - Create docs/clients.md with config for every supported client - Include Claude Code, Claude Desktop, Codex, Gemini, Cursor, Inspector - Add config file locations table and local checkout instructions - Note common pitfalls (absolute paths, venvs, socket isolation)
1 parent 3976aa0 commit efe45da

1 file changed

Lines changed: 140 additions & 0 deletions

File tree

docs/clients.md

Lines changed: 140 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,140 @@
1+
(clients)=
2+
3+
# MCP Clients
4+
5+
Copy-pasteable configuration for every supported MCP client. If your client isn't listed, any tool supporting MCP stdio transport will work with the JSON config pattern.
6+
7+
## Claude Code
8+
9+
```console
10+
$ claude mcp add libtmux -- uvx libtmux-mcp
11+
```
12+
13+
Config file: `.mcp.json` (project) or `~/.claude.json` (global).
14+
15+
## Claude Desktop
16+
17+
Add to `claude_desktop_config.json`:
18+
19+
```json
20+
{
21+
"mcpServers": {
22+
"libtmux": {
23+
"command": "uvx",
24+
"args": ["libtmux-mcp"],
25+
"env": {
26+
"LIBTMUX_SOCKET": "ai_workspace"
27+
}
28+
}
29+
}
30+
}
31+
```
32+
33+
## Codex CLI
34+
35+
```console
36+
$ codex mcp add libtmux -- uvx libtmux-mcp
37+
```
38+
39+
<details>
40+
<summary>config.toml format</summary>
41+
42+
Add to `~/.codex/config.toml`:
43+
44+
```toml
45+
[mcp_servers.libtmux]
46+
command = "uvx"
47+
args = ["libtmux-mcp"]
48+
```
49+
50+
</details>
51+
52+
## Gemini CLI
53+
54+
```console
55+
$ gemini mcp add libtmux uvx -- libtmux-mcp
56+
```
57+
58+
Config file: `~/.gemini/settings.json` (JSON format, same schema as Claude Desktop).
59+
60+
## Cursor
61+
62+
Add to `.cursor/mcp.json` (project) or `~/.cursor/mcp.json` (global):
63+
64+
```json
65+
{
66+
"mcpServers": {
67+
"libtmux": {
68+
"command": "uvx",
69+
"args": ["libtmux-mcp"]
70+
}
71+
}
72+
}
73+
```
74+
75+
## MCP Inspector
76+
77+
For testing and debugging:
78+
79+
```console
80+
$ npx @modelcontextprotocol/inspector
81+
```
82+
83+
## Config file locations
84+
85+
| Client | Config file | Format |
86+
|--------|-------------|--------|
87+
| Claude Code | `.mcp.json` (project) or `~/.claude.json` (global) | JSON |
88+
| Claude Desktop | `claude_desktop_config.json` | JSON |
89+
| Codex CLI | `~/.codex/config.toml` | TOML |
90+
| Gemini CLI | `~/.gemini/settings.json` | JSON |
91+
| Cursor | `.cursor/mcp.json` (project) or `~/.cursor/mcp.json` (global) | JSON |
92+
93+
## Local checkout (development)
94+
95+
For live development, point your client at a local checkout via `uv --directory`:
96+
97+
**Claude Code:**
98+
99+
```console
100+
$ claude mcp add --scope user libtmux -- uv --directory ~/work/python/libtmux-mcp run libtmux-mcp
101+
```
102+
103+
<details>
104+
<summary>Codex CLI / Gemini CLI / Cursor</summary>
105+
106+
**Codex CLI:**
107+
108+
```console
109+
$ codex mcp add libtmux -- uv --directory ~/work/python/libtmux-mcp run libtmux-mcp
110+
```
111+
112+
**Gemini CLI:**
113+
114+
```console
115+
$ gemini mcp add --scope user libtmux uv -- --directory ~/work/python/libtmux-mcp run libtmux-mcp
116+
```
117+
118+
**Cursor** — add to `~/.cursor/mcp.json`:
119+
120+
```json
121+
{
122+
"mcpServers": {
123+
"libtmux": {
124+
"command": "uv",
125+
"args": [
126+
"--directory", "~/work/python/libtmux-mcp",
127+
"run", "libtmux-mcp"
128+
]
129+
}
130+
}
131+
}
132+
```
133+
134+
</details>
135+
136+
## Common pitfalls
137+
138+
- **Absolute paths**: Some clients require absolute paths in config. Use `$HOME/...` or the full path instead of `~/...`.
139+
- **Virtual environments**: If using pip install (not uvx), ensure the venv is activated or use `uv run`.
140+
- **Socket isolation**: Set `LIBTMUX_SOCKET` in the `env` block to isolate the MCP server from your default tmux. See {ref}`configuration`.

0 commit comments

Comments
 (0)