feat(install): merge user settings and turn off bundled Claude Code skills #281

Merged
Defame1297 merged 2 commits from feat/280-merge-user-settings into main 2026-12-04 20:14:56 +00:00
2 changed files with 3 additions and 2 deletions
Showing only changes of commit f0aac594c3 - Show all commits

No files matched your search

+2 -1
View File
@@ -21,7 +21,8 @@ def merged_text(src_text, dest):
existing = json.load(f)
if not isinstance(existing, dict):
raise ValueError("top level is not a JSON object")
before = json.dumps(existing, indent=2, ensure_ascii=False)
# json.load accepts NaN and Infinity, which are not valid JSON.
before = json.dumps(existing, indent=2, ensure_ascii=False, allow_nan=False)
after = json.dumps(merge(existing, json.loads(src_text)), indent=2, ensure_ascii=False)
return None if after == before else after + "\n"
+1 -1
View File
@@ -147,7 +147,7 @@ else
fail "a second run changed the merged settings"
fi
for invalid in '{"model": "opus",' '["not an object"]' ''; do
for invalid in '{"model": "opus",' '["not an object"]' '{"x": NaN}' ''; do
BAD_HOME="$(new_home)"
BAD="$BAD_HOME/.claude/settings.json"
printf '%s' "$invalid" > "$BAD"