diff --git a/apps/cli/README.md b/apps/cli/README.md index 9ce1112..fd14155 100644 --- a/apps/cli/README.md +++ b/apps/cli/README.md @@ -1,4 +1,4 @@ -# @claudemesh/cli +# claudemesh-cli Client tool for claudemesh — install once per machine, join one or more meshes, and your Claude Code sessions can talk to peers on demand. @@ -7,7 +7,7 @@ meshes, and your Claude Code sessions can talk to peers on demand. ```sh # From npm (once published) -npm install -g @claudemesh/cli +npm install -g claudemesh-cli # Or from the monorepo during dev cd apps/cli && bun link diff --git a/apps/cli/package.json b/apps/cli/package.json index 04087a8..cb9ceaf 100644 --- a/apps/cli/package.json +++ b/apps/cli/package.json @@ -1,5 +1,5 @@ { - "name": "@claudemesh/cli", + "name": "claudemesh-cli", "version": "0.1.0", "description": "Claude Code MCP client for claudemesh — peer mesh messaging between Claude sessions.", "keywords": [ diff --git a/apps/cli/src/commands/install.ts b/apps/cli/src/commands/install.ts index c2740bc..684a7dd 100644 --- a/apps/cli/src/commands/install.ts +++ b/apps/cli/src/commands/install.ts @@ -90,7 +90,7 @@ function resolveEntry(): string { * Build the MCP server entry for Claude Code's config. * * Two modes: - * - Installed globally (npm i -g @claudemesh/cli): use `claudemesh` + * - Installed globally (npm i -g claudemesh-cli): use `claudemesh` * as the command, relies on it being on PATH. * - Local dev (bun apps/cli/src/index.ts): use `bun `. */ @@ -167,16 +167,25 @@ export function runInstall(): void { process.exit(1); } + // ANSI color helpers — stick to 8-color set so terminals without + // truecolor still render. Fall back to plain if NO_COLOR or dumb TERM. + const useColor = + !process.env.NO_COLOR && process.env.TERM !== "dumb" && process.stdout.isTTY; + const bold = (s: string) => (useColor ? `\x1b[1m${s}\x1b[22m` : s); + const yellow = (s: string) => (useColor ? `\x1b[33m${s}\x1b[39m` : s); + const dim = (s: string) => (useColor ? `\x1b[2m${s}\x1b[22m` : s); + console.log(`✓ MCP server "${MCP_NAME}" ${action}`); - console.log(` config: ${CLAUDE_CONFIG}`); + console.log(dim(` config: ${CLAUDE_CONFIG}`)); console.log( - ` command: ${desired.command}${desired.args?.length ? " " + desired.args.join(" ") : ""}`, + dim( + ` command: ${desired.command}${desired.args?.length ? " " + desired.args.join(" ") : ""}`, + ), ); console.log(""); - console.log("Restart Claude Code to load the MCP server."); - console.log("Then join a mesh:"); + console.log(yellow(bold("⚠ RESTART CLAUDE CODE")) + yellow(" for MCP tools to appear.")); console.log(""); - console.log(" claudemesh join "); + console.log(`Next: ${bold("claudemesh join ic://join/")}`); } export function runUninstall(): void { diff --git a/apps/cli/src/index.ts b/apps/cli/src/index.ts index e6255b7..16679b9 100644 --- a/apps/cli/src/index.ts +++ b/apps/cli/src/index.ts @@ -1,5 +1,5 @@ /** - * @claudemesh/cli entry point. + * claudemesh-cli entry point. * * Dispatches between two modes: * - `claudemesh mcp` → MCP server (stdio transport) diff --git a/apps/cli/src/mcp/server.ts b/apps/cli/src/mcp/server.ts index 298da5d..b92e989 100644 --- a/apps/cli/src/mcp/server.ts +++ b/apps/cli/src/mcp/server.ts @@ -1,5 +1,5 @@ /** - * MCP server (stdio transport) for @claudemesh/cli. + * MCP server (stdio transport) for claudemesh-cli. * * Starts BrokerClient connections for every mesh in config on boot, * then routes the 5 MCP tools through them. diff --git a/docs/QUICKSTART.md b/docs/QUICKSTART.md index 8ae12e2..fb876ae 100644 --- a/docs/QUICKSTART.md +++ b/docs/QUICKSTART.md @@ -21,14 +21,14 @@ That's it. ## Step 1 — Install the CLI *(~30s)* ```sh -npm install -g @claudemesh/cli +npm install -g claudemesh-cli claudemesh --version ``` You should see: ``` -@claudemesh/cli v0.1.x +claudemesh-cli v0.1.x ``` > **From source** (if npm install fails): clone the repo, then @@ -179,7 +179,7 @@ to memorize them. Just describe what you want in plain English. **`claudemesh: command not found`** → `npm install -g` may have installed to a path not on your `$PATH`. Try `npm bin -g` to see the install location, and add it to your shell -rc. Or use `npx @claudemesh/cli` until you fix the path. +rc. Or use `npx claudemesh-cli` until you fix the path. **`invalid invite: signature verification failed`** → The invite was tampered with or expired. Ask the mesh owner to diff --git a/docs/roadmap.md b/docs/roadmap.md index a740694..e2340bc 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -10,7 +10,7 @@ broker, ready for real teams. - Signed ed25519 identities + signed invite links (`ic://join/...`) - Hello-sig handshake auth against the broker - Hosted broker at `wss://ic.claudemesh.com/ws` -- `@claudemesh/cli` — join, list, leave, MCP server +- `claudemesh-cli` — join, list, leave, MCP server - Claude Code MCP tools: `list_peers`, `send_message`, `check_messages`, `set_summary`, `set_status` - Dashboard (beta): presence, live traffic, peer summaries