James Washington
writing about archive utils free game ideas replays
Agent hook

commit_gate: no wandering off with a dirty tree

Stops an AI from finishing a task while leaving its changes uncommitted.

built Sep 2026 updated Oct 2026 Upgrading the AI's workbench

how it works

Stop hook that keys on files this session actually edited (parsed from transcript Edit/Write calls) rather than cwd git status, so it never fires on repos the agent only read; blocks and lets the model write the commit.

Agent hook: A script that runs automatically at a moment in an AI session (before a command, when it stops) to steer or guard it.

githooksmulti-agentstop-hook

related

  • Git discipline for agent fleets AI skill Rules that stop many AI assistants working in the same code from trampling each other's changes.
  • ~/.claude config repo: deny-by-default .gitignore + secret pre-commit Automation Keeps James's AI configuration under version control without ever committing transcripts or passwords.
  • Agent git fleet: worktrees, sweeper, ship Automation Gives every AI session its own copy of the code, then automatically opens reviews for finished work and cleans up.
  • agent-merge: Jev-gated self-merge for agent branches Automation The one sanctioned way an AI may merge its own work: a script that reviews it first and refuses if it didn't show its work.
  • PostToolUse file soft-claim hook for agent collision detection Agent hook Every time an AI session edits a file, it quietly tells the dashboard, so two sessions editing the same file get flagged.
← everything I've built
© 2026 James Washington
github twitter rss