planning-with-files: Hook for Claude Code

.gemini/settings.json

AfterTool is a hook for Claude Code, Gemini CLI from OthmanAdi/planning-with-files. Its token cost is not measured, scanned A, original, MIT.

A hook that runs a shell script after the assistant changes files. A hook is an automatic action triggered by a tool event.

In plain words
What is it for?
Use it to run after-change project planning checks through the provided script.
Why use it?
It reminds the assistant to update progress after writing, editing, replacing, creating, or patching files. This helps keep a file-based plan current.

Hook for Claude CodeGemini CLI

Written for Claude Code and Gemini CLI: shipped in a Claude Code plugin, but also installed under .gemini/.

This is OthmanAdi/planning-with-files's own configuration. It tells Claude Code and Gemini CLI how to work on planning-with-files itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything planning-with-files configures →

Part of the planning-with-files plugin — 6 skills, 15 commands, 9 hooks shipped together

One of 4 entries in settings.json upstream. Installing this one merges just its entry into your config; the other 3 are separate, each on its own page.

About the project

OthmanAdi/planning-with-files is a planning system that stores an AI coding agent's task plan, findings, and progress in project files so the work can be recovered after context resets, crashes, or compaction. It is for long-running coding tasks across many agent tools, including Claude Code, Codex CLI, and Cursor. The catalogue entries are the project's commands, hooks, skills, plugin, and instruction for maintaining those planning files.

OthmanAdi/planning-with-files · 27,535 stars · on GitHub · gilded-laurel-c7nj.here.now

Reuse

Borrowing it

Nothing to install: this file belongs to OthmanAdi/planning-with-files. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/OthmanAdi/planning-with-files/master/.gemini/settings.json
Clone the repo
git clone --depth 1 https://github.com/OthmanAdi/planning-with-files

Made for: Claude Code, Gemini CLI.

Or install planning-with-files, the plugin that ships this one along with the rest of its 6 skills, 15 commands, 9 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for AfterTool

README.md
[![agentmods](https://agentmods.dev/badge/hooks/othmanadi/planning-with-files/after-tool/github.svg)](https://agentmods.dev/hooks/othmanadi/planning-with-files/after-tool)
Your own site
<a href="https://agentmods.dev/hooks/othmanadi/planning-with-files/after-tool"><img src="https://agentmods.dev/badge/hooks/othmanadi/planning-with-files/after-tool/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for AfterTool

Your own site · 80×15
<a href="https://agentmods.dev/hooks/othmanadi/planning-with-files/after-tool"><img src="https://agentmods.dev/badge/hooks/othmanadi/planning-with-files/after-tool.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
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 A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Security

Grade A, and why

AfterTool scanned grade A with 0 findings 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 1mo ago.

A static scan of the commands this hook runs, not an audit. A hook is shell that executes on your machine at the event it names, which is why every command in it is printed with what was found.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.gemini/settings.json · 16 lines

What it actually says

{
  "AfterTool": [
    {
      "matcher": "write_file|edit_file|replace|create_file|patch",
      "hooks": [
        {
          "name": "planning-after-tool",
          "type": "command",
          "command": "$GEMINI_PROJECT_DIR/.gemini/hooks/after-tool.sh",
          "timeout": 5000,
          "description": "Remind agent to update progress after file changes"
        }
      ]
    }
  ]
}
Same file

What else settings.json configures

This page is one entry in a file that holds 4. Installing the file brings all of them; each is measured and scanned on its own page.

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. 1mo ago First seen · 16 lines scan A 58594a5d389e

Subscribe to this mod's changes

AfterTool is a hook published in the GitHub repository OthmanAdi/planning-with-files (27,535 stars, last pushed 2d ago), licensed MIT. Its token cost is not measured: a hook is shell that never enters the context. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-08.