programs.claude-code.settings

Home-Manager option

JSON configuration for Claude Code settings.json

type: JSON value
Default
{ }
Example
{ hooks = { PostToolUse = [ { hooks = [ { command = "nix fmt $(jq -r &#x27;.tool_input.file_path&#x27; <<< &#x27;$CLAUDE_TOOL_INPUT&#x27;)"; type = "command"; } ]; matcher = "Edit|MultiEdit|Write"; } ]; PreToolUse = [ { hooks = [ { command = "echo &#x27;Running command: $CLAUDE_TOOL_INPUT&#x27;"; type = "command"; } ]; matcher = "Bash"; } ]; }; includeCoAuthoredBy = false; model = "claude-3-5-sonnet-20241022"; permissions = { additionalDirectories = [ "../docs/" ]; allow = [ "Bash(git diff:*)" "Edit" ]; ask = [ "Bash(git push:*)" ]; defaultMode = "acceptEdits"; deny = [ "WebFetch" "Bash(curl:*)" "Read(./.env)" "Read(./secrets/**)" ]; disableBypassPermissionsMode = "disable"; }; statusLine = { command = "input=$(cat); echo \"[$(echo \"$input\" | jq -r &#x27;.model.display_name&#x27;)] ๐Ÿ“ $(basename \"$(echo \"$input\" | jq -r &#x27;.workspace.current_dir&#x27;)\")\""; padding = 0; type = "command"; }; theme = "dark"; }
declared in: <home-manager/modules/programs/claude-code.nix>source unavailable