What problem does it solve? Repositories about to be pushed, shared, or published risk leaking credentials (passwords, tokens, private keys) and internal identifiers (domains, node names, project names). gitleaks alone cannot judge repo-specific identifiers, so a single-layer scan gives false confidence. ## Core Features & Use Cases - Two-layer gate design: gitleaks custom [[rules]] for credentials plus a grep -E pattern layer for internal identifiers, combined in one sanitize-check.sh script. - Ready-to-adapt templates: Ships gitleaks.toml with placeholder rules and commented allowlist entries, and a gate script with three file-selection modes (tracked, untracked/modified, explicit paths). - Enforcement ladder: Guides wiring from manual runs to an AGENTS.md pointer to a pre-push hook that scans only the commits being pushed. - Use Case: Before open-sourcing an internal repo, run the gate to catch a database connection string in an old commit and internal hostnames in docs, then add a pre-push hook so future pushes are blocked on any finding. ## Quick Start Set up a gitleaks credential and sanitize gate for this repository before it is pushed public.