11 pages for --cwd.
Titles and paths first, then pages whose text carries it. Each row opens that page as this site last read it.
Manage multiple agents with agent view
Claude Code CLI · in the page
agent-view
…you opened agent view from. To narrow the list to one project, pass `--cwd`: ```bash theme={null} claude agents --cwd ~/projects/my-app ``` This shows only sessions started under that directory. It…
CLI reference
Claude Code CLI · in the page
cli-reference
…gent-view) to monitor and dispatch parallel background sessions. Use `--cwd <path>` to show only sessions started under that directory, or `--json` to print active sessions as a JSON array for scripti…
Week 20 · May 11–15, 2026
Claude Code CLI · in the page
whats-new/2026-w20
…ip-permissions`) to configure background sessions, and `claude agents --cwd <path>` scopes the session list to a directoryNew hook `args: string[]` exec form spawns the command directly without a shel…
CLI client
Model Context Protocol · in the page
docs/2026-07-28/tools/inspector/cli
…method servers/add --server my-server # Edit: change the target, -e, --cwd, --header, or --protocol-era, or rename it mcp-inspector --cli --method servers/edit --server my-server --rename my-renamed-…
Configuration and flags
Model Context Protocol · in the page
docs/2026-07-28/tools/inspector/configuration
…ver-url <url>` | Server URL for SSE/HTTP. | Ad-hoc targets only. | | `--cwd <path>` | Working directory for a stdio server process. | None | | `-e <KEY=VALUE>` | Environment variables for a stdio serv…
Recipes
Model Context Protocol · in the page
docs/2026-07-28/tools/inspector/recipes
…process environment variables with `-e` and a working directory with `--cwd`: ```bash theme={null} mcp-inspector -e API_KEY=abc123 -e REGION=us-east-1 --cwd ~/projects/my-server \ node build/index.…
TUI client
Model Context Protocol · in the page
docs/2026-07-28/tools/inspector/tui
…r-selection-flags) (`--server-url`, `--transport`, `--header`, `-e`, `--cwd`) plus `--protocol-era` for an ad-hoc server, and the [OAuth client flags](/docs/2026-07-28/tools/inspector/configuration.md…
CLI client
Model Context Protocol · in the page
docs/draft/tools/inspector/cli
…method servers/add --server my-server # Edit: change the target, -e, --cwd, --header, or --protocol-era, or rename it mcp-inspector --cli --method servers/edit --server my-server --rename my-renamed-…
Configuration and flags
Model Context Protocol · in the page
docs/draft/tools/inspector/configuration
…ver-url <url>` | Server URL for SSE/HTTP. | Ad-hoc targets only. | | `--cwd <path>` | Working directory for a stdio server process. | None | | `-e <KEY=VALUE>` | Environment variables for a stdio serv…
Recipes
Model Context Protocol · in the page
docs/draft/tools/inspector/recipes
…process environment variables with `-e` and a working directory with `--cwd`: ```bash theme={null} mcp-inspector -e API_KEY=abc123 -e REGION=us-east-1 --cwd ~/projects/my-server \ node build/index.…
TUI client
Model Context Protocol · in the page
docs/draft/tools/inspector/tui
…r-selection-flags) (`--server-url`, `--transport`, `--header`, `-e`, `--cwd`) plus `--protocol-era` for an ad-hoc server, and the [OAuth client flags](/docs/draft/tools/inspector/configuration.md#cli-…