git hooks
30 articles about git hooks in AI news
Claude Code Introduces Interactive /init Command to Automate Project Configuration
Anthropic's Claude Code has launched a new interactive /init command that interviews developers to automatically configure CLAUDE.md files, Git hooks, and skills. This reduces manual setup time for AI-assisted coding workflows.
Git Hook + Claude Code: How to Force Your AI Agent to Write Commit
Enforce commit quality with a commit-msg hook, not prompts. This hard gate forces Claude Code to explain 'why', yielding atomic commits and a searchable git history.
Stop Relying on CLAUDE.md for Guarantees: Build Deterministic Hooks Instead
Claude Code hooks in settings.json let you run deterministic shell commands on SessionStart, PreToolUse, PostToolUse, and other events—replacing unreliable CLAUDE.md instructions for critical behaviors like blocking dangerous commands or injecting context.
GitHub's Former CEO Launches Distributed Git Network for AI Coding Agents
Claude Code users should monitor Nat Friedman's distributed Git network for faster agentic coding workflows. The new network optimizes Git for AI agents, potentially reducing clone/push latency.
Two Bash Hooks Cut an Anthropic Bill From $312 to $156
A developer halved their Anthropic bill from $312 to $156 by adding two Bash hooks to Claude Code that intercept retry spirals and block dangerous deploys.
Dify AI Workflow Platform Hits 136K GitHub Stars as Low-Code AI App Builder Gains Momentum
Dify, an open-source platform for building production-ready AI applications, has reached 136K stars on GitHub. The platform combines RAG pipelines, agent orchestration, and LLMOps into a unified visual interface, eliminating the need to stitch together multiple tools.
How to Auto-Approve Safe WebFetches While Blocking Suspicious URLs with Hooks
Use Claude Code's PreToolUse hooks to automatically allow clean documentation URLs while forcing manual review for any URL containing query parameters, eliminating repetitive prompts without sacrificing security.
Origin CLI: Open-Source Git Blame for AI Agents Tracks Claude Code, Cursor, and Gemini Contributions
Origin is a new open-source CLI tool that adds AI attribution to git commits, tagging each line with which agent wrote it, the prompt, model, and cost. It works offline with Claude Code, Cursor, and Gemini, storing data in git notes.
7 Production-Ready Agent Hooks You Can Copy Into Your CLAUDE.md Today
Agent hooks in CLAUDE.md automate context management, testing, and deployment, turning Claude Code from a chat tool into a proactive development partner.
Track Every Claude Code Session Automatically with This GitHub Hook
Install claude-session-tracker to automatically save all your Claude Code conversations as GitHub Issues linked to a Projects board—no lost context, searchable history.
Graft: Replace MCP Tool Calls with a Semantic Code Map That Cuts Agent
Install Graft via npm, run `graft init`, and Claude Code gets a persistent semantic map via hooks — cutting exploration tool calls and boosting SWE-bench Verified to 66%.
Token-Saving Tools Overpromise: Real Benchmark Shows 6–32% Savings, Not 60–90%
Token-saving tools deliver 6–32% savings, not 60–90%. In Claude Code, lazy MCP loading means tools often go unused—enable them with hooks and measure full sessions.
Claude Agentic Framework Uses 20 Specialized Agents to Enforce a 3-Stage
The Claude Agentic Framework enforces a Spec → Build → Review pipeline with 20 specialized agents and PowerShell hooks, preventing Claude Code from coding too early or finishing incomplete.
Claude Code Digest — Jul 13–Jul 16
Claude Code is no longer being treated like a chat assistant: the winning pattern this week is deterministic hooks, policy gates, and verification layers wrapped around an agent that can now hit 80.8% SWE-Bench.
Build a Self-Sustaining Claude Code Environment: The Complete 14-Part System
Build a self-sustaining Claude Code environment with 14 components: memory, skills, autonomy, guardrails, and monitoring. Connect them into a feedback loop where measurements flow back into memory. Use CLAUDE.md and hooks.
Claude Code Digest — Jul 10–Jul 13
Claude Code is crossing the line from “assistant” to “agent runtime”: the winning teams are the ones adding verification, hooks, and policy gates instead of trusting the model.
5 Guardrails for Letting Claude Code Open Its Own Pull Requests
Let Claude Code open PRs autonomously with 5 guardrails: branch naming, scoped tasks, structured commits, path-based auto-merge, and blocking destructive git commands like reset --hard.
3 CLAUDE.md Patterns That Cut Claude Code Configuration Time by 50%
CLAUDE.md with decision matrices, Bash hooks, and agentic workflow blocks reduces configuration time 50% and retry costs 30%.
JetBrains IDE Now Supports Codex Agent and MCP Server Management — Here's
JetBrains adds Codex agent, MCP server management, and approval controls. Claude Code users should compare MCP management UX and consider hooks for CLI workflows.
Muxer: Open-Source Model Multiplexer Slashes Claude Code Costs by Routing
Muxer reduces Claude Code costs by multiplexing models per subtask via agent frontmatter and session hooks. Keep Fable/Opus for planning; route boilerplate to Haiku.
5 Harness Internals That Changed How I Use Claude Code Daily
Rebuilding Claude Code's harness reveals that CLAUDE.md layers on a hidden base prompt, hooks can block tool calls, and subagents need abort trees—5 actionable takeaways for daily use.
Claude Code Digest — Jun 07–Jun 10
The biggest shift this week: teams are stripping 60% of prescriptive skill text, then using hooks + MCP + Temporal to make Claude Code more reliable than prompt-only workflows.
Stop Telling Claude to 'Be Careful' — 3 Hook Tools That Fix What Prompts Can't
Throughline, Caveat, and Spotter are three npm tools that use Claude Code hooks to fix context bloat, past-trap memory, and missed tool calls — problems CLAUDE.md instructions can't solve.
Pylon: Self-Host Your Own AI Agent Pipeline That Fixes Sentry Errors via
Pylon is a self-hosted daemon that triggers sandboxed Claude Code agents from webhooks (Sentry, cron, chat) and reports results with human approval — no data leaves your machine.
Claude Code Routines: Automate Code Reviews
Automate Claude Code tasks like scheduled code reviews or deployment hooks using the new Routines feature, which runs on Anthropic's infrastructure.
How Telemetry Settings Are Silently Costing You Cache Tiers (And How To Fix It)
A confirmed bug links telemetry settings to cache TTL; disabling telemetry defaults you to 5-minute cache, increasing costs. Use environment variables and hooks to mitigate.
Anthropic's Silent Cache TTL Cut
Claude Code's default cache TTL was silently reduced to 5 minutes on April 2, drastically increasing token costs. Use hooks and settings to mitigate the impact.
Claude Code Best Practice Repo Hits 19.7K Stars with 84 Anthropic Tips
A GitHub repository called 'claude-code-best-practice' has amassed 19.7K stars by compiling 84 production tips from Anthropic's Claude Code creators. It provides a full open-source framework for moving from basic usage to advanced agentic workflows.
Anthropic's Claude Code Now Acts as Autonomous PR Agent, Fixing CI Failures & Review Comments in Background
Anthropic has transformed Claude Code into a persistent pull request agent that monitors GitHub PRs, reacts to CI failures and reviewer comments, and pushes fixes autonomously while developers are offline. The system runs on Anthropic-managed cloud infrastructure, enabling full repo operations without local compute.
How This Obsidian Vault Template Gives Claude Code a Long-Term Memory
A GitHub template creates a persistent knowledge graph for Claude Code, eliminating session amnesia and compounding engineering decisions across conversations.