Блокировка обхода git-хуков в Claude Code

★ 8.5 · devops

block-no-verify-hook is a Claude Code skill that configures a PreToolUse hook to intercept and block --no-verify and --no-gpg-sign flags in git commands before they execute. The hook is defined in .claude/settings.json with a Bash matcher: it inspects the $TOOL_INPUT environment variable using a grep regex and exits with code 2 when a bypass flag is detected inside a git command, causing Claude Code to reject the tool call entirely. This prevents AI agents from skipping pre-commit hooks that enforce linting, formatting, test runs, and security scanning, as well as GPG commit-signing policies. The configuration can be applied per-project or globally via ~/.claude/settings.json, and the regex pattern is straightforward to extend with additional flags such as --force. It is intended for teams that need reliable quality gates when using Claude Code or similar AI coding agents.