fix(cc-config): .claude.json sits BESIDE ~/.claude by default, not inside it
The previous commit routed the read through getClaudeHome(), which appends /.claude when CLAUDE_HOME is unset — pointing the dashboard at ~/.claude/.claude.json, a file the CLI never writes by default. Verified against the real binary: with CLAUDE_CONFIG_DIR unset the CLI writes $HOME/.claude.json; with it set, .claude.json sits flat inside that dir. Branch on CLAUDE_HOME accordingly. The test now drives a fake claude that writes where the real one does and asserts getClaudeJsonPath() names that exact file, under both branches — the previous test only restated the implementation.
This commit is contained in:
@@ -327,6 +327,12 @@ const schemas = {
|
||||
"Where the definition was found, e.g. `~/.claude.json (top-level)`, `~/.claude.json (projects[<root>])`, or `~/.claude/settings.json`.",
|
||||
example: "~/.claude.json (top-level)",
|
||||
},
|
||||
removable: {
|
||||
type: "boolean",
|
||||
description:
|
||||
"False when no `claude mcp` scope can address this entry (currently only ~/.claude/settings.json-sourced servers), so POST /mcp/remove has no scope that would find it. Absent/true means removable.",
|
||||
example: true,
|
||||
},
|
||||
kind: {
|
||||
type: "string",
|
||||
enum: ["http", "stdio", "unknown"],
|
||||
|
||||
Reference in New Issue
Block a user