* feat(cli,tui): normalize --catalog / --config with web; update --help (#1347) Bring the CLI and TUI in line with the web catalog vs read-only session model introduced in #1481/#1483, and close the outstanding --help item from #1347. Core (core/mcp/node/config.ts): - Add `catalogPath` to ServerConfigOptions (writable catalog slot). - `resolveServerSource()` picks the active source: `--catalog` (writable, seed-if-missing) wins over `--config` (read-only, error-if-missing). - Writable sources seed an empty `{"mcpServers":{}}` on first run (matches the web backend) instead of erroring; read-only `--config` still errors. - `serverSourceConflict()` shared conflict matrix (mirrors run-web): --catalog/--config mutually exclusive; neither combines with an ad-hoc target. - `readServerListFile()` public loader for runners (TUI) needing the raw map. - Rename `withDefaultConfigPath` → `withDefaultCatalogPath`; the no-flag default now fills the writable catalog slot, not --config. CLI / TUI: - Add `--catalog <path>` (+ MCP_CATALOG_PATH) and re-document `--config` as a read-only session in --help. - Enforce the shared conflict matrix before resolution. Full writable persistence/CRUD threading remains deferred to #1482 / #1432 (CLI/TUI are read consumers today; the split surfaces as seed- vs error-on-missing). Tests: core resolution matrix (source/conflict/seed/read-only), CLI catalog + conflict integration tests, TUI loadTuiServers unit tests. READMEs updated. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * test(launcher): add smoke:cli + smoke:tui e2e launcher smokes (#1347) The launcher smokes only checked `--help` for --cli/--tui; nothing exercised the launcher → CLI/TUI → core path on the built artifact (only smoke:web did, for web). Add two end-to-end smokes wired into validate:launcher between smoke:launcher and smoke:web: - smoke:cli (scripts/smoke-cli.mjs): runs `--cli` against the bundled stdio test server via a temp --catalog and asserts tools/list returns the tools, plus the #1347 resolution paths — default-catalog seed-on-missing, read-only --config error-without-seed, and the --catalog/--config conflict. - smoke:tui (scripts/smoke-tui.mjs): launches `--tui --catalog <temp>` and asserts the Ink app renders its first frame ("MCP Servers") within a timeout, then SIGTERMs it (shallow boot/render check). Both build test-servers/build on demand if missing. Docs updated (AGENTS.md validate description, launcher README). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * refactor: address review on #1499 (comment accuracy, CLI/TUI flag parity) Review feedback from @claude on PR #1499 (all non-blocking): - Align CLI catalogPath resolution with the TUI: `options.catalog?.trim() || process.env.MCP_CATALOG_PATH` so an explicit empty `--catalog ""` falls back to MCP_CATALOG_PATH identically in both front-ends (CLI used `??`, which only guards undefined/null). - Clarify the `serverSourceConflict` comment: it mirrors only the source-selection portion of web's matrix and deliberately omits web's `--header` rejection, since CLI/TUI merge --header into per-server settings. - Note the deliberate --header broadcast semantics in loadTuiServers. - Share an EMPTY_CATALOG_CONTENT constant between seedEmptyCatalog and readServerListContent instead of two separate literals. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * refactor(cli): trim --config to match --catalog and the TUI (#1499 review) Cosmetic uniformity follow-up from the re-review: configPath now uses `options.config?.trim() || undefined`, matching the catalog slot above it and the TUI. Behavior is unchanged (resolveServerSource/serverSourceConflict already trim downstream). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
83 lines
3.1 KiB
JSON
83 lines
3.1 KiB
JSON
{
|
|
"name": "@modelcontextprotocol/inspector",
|
|
"version": "2.0.0",
|
|
"description": "The Model Context Protocol Inspector",
|
|
"keywords": [
|
|
"MCP",
|
|
"inspector"
|
|
],
|
|
"homepage": "https://github.com/modelcontextprotocol/inspector#readme",
|
|
"bugs": {
|
|
"url": "https://github.com/modelcontextprotocol/inspector/issues"
|
|
},
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git+https://github.com/modelcontextprotocol/inspector.git"
|
|
},
|
|
"license": "MIT",
|
|
"author": "The MCP Maintainers and Community",
|
|
"type": "module",
|
|
"bin": {
|
|
"mcp-inspector": "./clients/launcher/build/index.js"
|
|
},
|
|
"files": [
|
|
"clients/launcher/build",
|
|
"clients/web/build",
|
|
"clients/web/dist",
|
|
"clients/cli/build",
|
|
"clients/tui/build",
|
|
"scripts/install-clients.mjs"
|
|
],
|
|
"scripts": {
|
|
"build": "npm run build:web && npm run build:cli && npm run build:tui && npm run build:launcher",
|
|
"build:web": "cd clients/web && npm run build",
|
|
"build:cli": "cd clients/cli && npm run build",
|
|
"build:tui": "cd clients/tui && npm run build",
|
|
"build:launcher": "cd clients/launcher && npm run build",
|
|
"prepack": "npm run build",
|
|
"test:cli": "cd clients/cli && npm run test",
|
|
"test:tui": "cd clients/tui && npm run test",
|
|
"validate": "npm run validate:web && npm run test:cli && npm run test:tui && npm run validate:launcher",
|
|
"validate:web": "cd clients/web && npm run validate",
|
|
"validate:launcher": "npm run build:cli && npm run build:tui && npm run build:launcher && npm run smoke:launcher && npm run smoke:cli && npm run smoke:tui && npm run smoke:web",
|
|
"smoke:launcher": "node clients/launcher/build/index.js --help && node clients/launcher/build/index.js --cli --help && node clients/launcher/build/index.js --tui --help",
|
|
"smoke:cli": "node scripts/smoke-cli.mjs",
|
|
"smoke:tui": "node scripts/smoke-tui.mjs",
|
|
"smoke:web": "node scripts/smoke-web.mjs",
|
|
"test": "cd ./clients/web/ && npm run test && cd ../cli && npm run test && cd ../tui && npm run test",
|
|
"test:coverage": "cd ./clients/web/ && npm run test:coverage",
|
|
"test:storybook": "cd ./clients/web/ && npm run test:storybook",
|
|
"inspector": "node clients/launcher/build/index.js",
|
|
"web": "node clients/launcher/build/index.js --web",
|
|
"web:dev": "node clients/launcher/build/index.js --web --dev",
|
|
"postinstall": "node scripts/install-clients.mjs",
|
|
"install:clients": "node scripts/install-clients.mjs"
|
|
},
|
|
"dependencies": {
|
|
"@hono/node-server": "^1.19.14",
|
|
"@modelcontextprotocol/ext-apps": "^1.7.1",
|
|
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
"@napi-rs/keyring": "^1.3.0",
|
|
"@vitejs/plugin-react": "^6.0.0",
|
|
"ajv": "^8.17.1",
|
|
"atomically": "^2.1.1",
|
|
"chokidar": "^4.0.3",
|
|
"commander": "^13.1.0",
|
|
"hono": "^4.12.18",
|
|
"ink": "^6.0.0",
|
|
"ink-form": "^2.0.1",
|
|
"ink-scroll-view": "^0.3.6",
|
|
"open": "^10.2.0",
|
|
"pino": "^9.14.0",
|
|
"react": "^19.2.4",
|
|
"vite": "^8.0.0",
|
|
"zod": "^4.3.6",
|
|
"zustand": "^5.0.13"
|
|
},
|
|
"overrides": {
|
|
"ink-select-input": "^6.2.0"
|
|
},
|
|
"engines": {
|
|
"node": ">=22.7.5"
|
|
}
|
|
}
|