settings

A Claude Code settings file defining allowed tools and automated actions that run when a session starts or after tools edit files. It also includes a rule for checking the size of selected project memory and scratch files.

In plain words
What is it for?
Use it to configure Claude Code permissions, session-start messages, post-edit checks, and allowed formatting, linting, type-checking, testing, and build commands.
Why use it?
It sets project-specific tool permissions and reminders, helping keep recurring checks and session-start instructions consistent.

Settings file for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add settings/fo0/clawstash/settings
Clone the repo
git clone --depth 1 https://github.com/fo0/clawstash

Made for: Claude Code.

Per session not measured What this adds to a session before it is invoked.
When invoked not measured Not applicable: nothing here is loaded into a session.
Security scan B 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Security

Grade B, and why

settings scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

"command": "cmd=$(jq -r '.tool_input.command // empty'); if echo \"$cmd\" | grep -qE 'git commit'; then cd \"$CLAUDE_PROJECT_DIR\" || exit 0; staged=$(git diff --cached --name-only 2>/dev/null | grep -E '^(\\.claude/|CLA
.claude/settings.json · 53 lines

How it starts

The opening of the file, as written. The whole thing — 53 lines — stays where its author put it; the contents beside it link to each section on GitHub.

{
  "$schema": "https://json.schemastore.org/claude-code-settings.json",
  "permissions": {
    "allow": [
      "mcp__claude-code-remote__*",
      "mcp__Claude_Code_Remote__*",
      "mcp__claude_code_remote__*",
      "mcp__github__subscribe_pr_activity",
      "mcp__github__unsubscribe_pr_activity",
      "Bash(npm run format)",
      "Bash(npm run format:check)",
      "Bash(npm run lint)",
      "Bash(npx tsc --noEmit)",
      "Bash(npm test)",
      "Bash(npm run build)"
    ]
  },
  "hooks": {
    "SessionStart": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "echo 'Session start -- read MEMORY.md and SCRATCHPAD.md to restore context. Check BACKLOG.md only if user references prior findings.'"
          }
        ]
      }
    ],
    "PostToolUse": [
      {
        "matcher": "Edit|Write",
        "hooks": [
          {
            "type": "command",
            "command": "over=\"\"; for spec in \"CLAUDE.md 20000\" \"MEMORY.md 16000\" \"SCRATCHPAD.md 8000\"; do set -- $spec; f=\"$CLAUDE_PROJECT_DIR/$1\"; [ -f \"$f\" ] || continue; c=$(wc -c < \"$f\"); [ \"$c\" -gt \"$2\" ] && over=\"$over $1 $c/$2 chars;\"; done; if [ -n \"$over\" ]; then printf '%s' '{\"hookSpecificOutput\":{\"hookEventName\":\"PostToolUse\",\"additionalContext\":\"Context budget exceeded --'\"$over\"' offload now per agent_docs/context_budget.md: MOVE content out (CLAUDE.md sections to agent_docs/, memory entries to docs/adr/ or agent_docs/memory_archive/) and leave a one-line pointer. Never delete to fit.\"}}'; fi; exit 0"
          }
        ]
      }
    ],
    "PreToolUse": [
      {
        "matcher": "Bash",
        "hooks": [
          {
            "type": "command",
            "command": "cmd=$(jq -r '.tool_input.command // empty'); if echo \"$cmd\" | grep -qE 'git commit'; then cd \"$CLAUDE_PROJECT_DIR\" || exit 0; staged=$(git diff --cached --name-only 2>/dev/null | grep -E '^(\\.claude/|CLAUDE\\.md|AGENTS\\.md|agent_docs/|docs/w

Read the full file on GitHub · 53 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 53 lines scan B 1ca82e1ee360

Subscribe to this mod's changes

settings is a settings file published in the GitHub repository fo0/clawstash (1 stars, last pushed yesterday), licensed MIT. Its token cost is not measured: this kind of file is read by the harness, not the model. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.