claude: link ~/.claude.json straight to persistent storage #1500

Merged
JakeHillion merged 1 commits from jj/plvmvumpotlw into main 2026-12-05 20:21:51 +00:00
Owner

Claude Code saves ~/.claude.json by writing a new file next to the target
and renaming it over it, following a symlink only one level. The
impermanence module persisted the file as a link to a home-manager store
entry that links on to /data, so Claude Code tried to write into the
read-only store and every save failed. The persisted file has not changed
since it was created, so each session starts from stale state, including
a cached model list that marks Fable as unavailable.

Replaced the file persistence with an activation step that links
~/.claude.json directly to its file in persistent storage. One level of
symlink leads Claude Code to write and rename within /data, and the
existing file is kept.

Test plan:

  • CI
  • Built maverick's toplevel: the activation links ~/.claude.json to
    /data/users/jake/.claude.json and home-manager no longer manages it
Claude Code saves ~/.claude.json by writing a new file next to the target and renaming it over it, following a symlink only one level. The impermanence module persisted the file as a link to a home-manager store entry that links on to /data, so Claude Code tried to write into the read-only store and every save failed. The persisted file has not changed since it was created, so each session starts from stale state, including a cached model list that marks Fable as unavailable. Replaced the file persistence with an activation step that links ~/.claude.json directly to its file in persistent storage. One level of symlink leads Claude Code to write and rename within /data, and the existing file is kept. Test plan: - CI - Built maverick's toplevel: the activation links ~/.claude.json to /data/users/jake/.claude.json and home-manager no longer manages it
JakeHillion changed title from Jj/plvmvumpotlw to claude: link ~/.claude.json straight to persistent storage 2026-12-05 20:18:31 +00:00
JakeHillion scheduled this pull request to auto merge when all checks succeed 2026-12-05 20:19:58 +00:00
JakeHillion added 1 commit 2026-12-05 20:20:14 +00:00
claude: link ~/.claude.json straight to persistent storage
commit-validation / validate-single-commit (pull_request) Successful in 10s
buildbot/nix-eval Build done. (30 warnings)
buildbot/nix-build Build done.
buildbot/nix-effects Build done.
ed060a431a
Claude Code saves ~/.claude.json by writing a new file next to the target
and renaming it over it, following a symlink only one level. The
impermanence module persisted the file as a link to a home-manager store
entry that links on to /data, so Claude Code tried to write into the
read-only store and every save failed. The persisted file has not changed
since it was created, so each session starts from stale state, including
a cached model list that marks Fable as unavailable.

Replaced the file persistence with an activation step that links
~/.claude.json directly to its file in persistent storage. One level of
symlink leads Claude Code to write and rename within /data, and the
existing file is kept.

Test plan:
- CI
- Built maverick's toplevel: the activation links ~/.claude.json to
  /data/users/jake/.claude.json and home-manager no longer manages it
JakeHillion force-pushed jj/plvmvumpotlw from c2c54869a1 to ed060a431a 2026-12-05 20:20:14 +00:00 Compare
JakeHillion merged commit ed060a431a into main 2026-12-05 20:21:51 +00:00
JakeHillion deleted branch jj/plvmvumpotlw 2026-12-05 20:21:53 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: JakeHillion/nixos#1500