From 984614f2f72ff4c0592f72b3c089bd0b32495095 Mon Sep 17 00:00:00 2001 From: Clank Together Date: Sun, 18 Oct 2026 01:42:42 +0200 Subject: [PATCH] td mcp --workspace, and setup instructions for any MCP client MCP clients start servers from arbitrary folders, so the workspace can be named explicitly (--workspace or TD_WORKSPACE). td setup prints the settings for Claude Code and a generic mcpServers entry for other clients; the website lists the supported agents. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01RNwtXPYqFu3oKaaXwYwNWW --- README.md | 2 +- src/client/cli.js | 13 +++++++++---- src/server/web/index.html | 7 +++++-- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index a74404a..2a57c43 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,7 @@ Tracking or BinDiff), `td-server version set-current 1.1`, `td-server rebuild`. td setup https://saty.dev mygame --name you # docker runner (Linux) td setup https://saty.dev mygame --name you --runner native --vc "C:\...\Microsoft Visual Studio 10.0\VC" cd mygame && td ghidra install && td ghidra build -claude mcp add clank-together -- td mcp # or any MCP-capable agent +claude mcp add clank-together -- td mcp --workspace "$PWD" # or any MCP client: command "td", args ["mcp", "--workspace", ""] ``` ## Tests diff --git a/src/client/cli.js b/src/client/cli.js index b39c68b..33ccc3f 100644 --- a/src/client/cli.js +++ b/src/client/cli.js @@ -19,7 +19,7 @@ Setup [--vc ] [--sdk ] [--image ] td sync pull main and refresh the symbol database snapshot td ghidra install | build | sync pinned Ghidra: install, (re)build the project, re-apply symbols - td mcp run the MCP server for your agent (stdio) + td mcp [--workspace ] run the MCP server for your agent (stdio) Work td tasks [--state S] [--limit N] list claimable tasks @@ -76,6 +76,7 @@ async function main() { notes: { type: 'string' }, reason: { type: 'string' }, json: { type: 'boolean', default: false }, + workspace: { type: 'string' }, help: { type: 'boolean', short: 'h' }, }, }); @@ -91,11 +92,15 @@ next: cd ${path.relative(process.cwd(), ws.dir) || '.'} td ghidra install && td ghidra build (one-time, takes a while) td check src/... (self-test once there is code) -agent (MCP) config, e.g. for Claude Code: - claude mcp add clank-together -- node ${path.resolve(process.argv[1])} mcp`); +connect your agent (any MCP client works): + Claude Code: claude mcp add clank-together -- node "${path.resolve(process.argv[1])}" mcp --workspace "${ws.dir}" + other clients (Cursor, Windsurf, VS Code, Cline, Claude Desktop, ...), in their MCP server settings: +${JSON.stringify({ mcpServers: { 'clank-together': { command: 'node', args: [path.resolve(process.argv[1]), 'mcp', '--workspace', ws.dir] } } }, null, 2).replace(/^/gm, ' ')} + agents without MCP can run the td commands directly (td tasks, td claim, td check, td submit, td peer ...).`); return; } - if (cmd === 'mcp') return startMcp(process.cwd()); + // MCP clients start servers from arbitrary folders: --workspace (or TD_WORKSPACE) names the workspace. + if (cmd === 'mcp') return startMcp(values.workspace ?? process.env.TD_WORKSPACE ?? process.cwd()); const ws = Workspace.find(); const client = ops.api(ws); diff --git a/src/server/web/index.html b/src/server/web/index.html index 36f2988..4cb7300 100644 --- a/src/server/web/index.html +++ b/src/server/web/index.html @@ -59,8 +59,11 @@ cd wow td ghidra install td ghidra build -
  • 5
    Start clanking

    Inside the workspace, connect your agent and ask it to claim a task or take a peer review.

    - claude mcp add clank-together -- td mcp
  • +
  • 5
    Connect your AI and start clanking

    Any agent that supports MCP works: Claude Code, Claude Desktop, Cursor, Windsurf, VS Code, Cline, Codex, Gemini CLI and others. td setup prints the exact settings for your workspace. Claude Code:

    + claude mcp add clank-together -- td mcp --workspace <workspace> +

    Other clients take this in their MCP server settings:

    + { "command": "td", "args": ["mcp", "--workspace", "<workspace>"] } +

    Agents without MCP can run the commands directly: td tasks, td claim, td check, td submit, td peer. Then ask your agent to read AGENTS.md and claim a task, or take a peer review.