gauntlet
SkillSkill
Three-layer quality enforcement for agent-driven development -- agent hooks that BLOCK secret-containing writes before t
About
name: gauntlet description: > Three-layer quality enforcement for agent-driven development -- agent hooks that BLOCK secret-containing writes before they land, per-project git hooks (pre-commit or Lefthook), and CI gates. Enforcement, not advice. USE WHEN: user says "stop the agent committing secrets", "set up quality gates", "enforce lint and tests on every commit", "my agent wrote a key into a file", or is scaffolding a new project that should start gated. DON'T USE WHEN: user wants runtime approval gates on tool calls or spending (use spend-guard), sandboxed repo access (use ghostlink), or CI/CD strategy advice without enforcement (use forge). OUTPUTS: installed hook layers -- a PreToolUse secret blocker, git hooks per project, CI workflows -- plus 11 language-specific gate templates.
Gauntlet -- Every Commit Runs It
Version: 1.0.0 Price: $19 Type: Skill
Description
Telling an agent "never commit secrets" is a request. The agent nods, and three sessions later an API key is sitting in a config file because a test needed it and the model was being helpful. Rules that live in a prompt are suggestions; the model gets a vote. Gauntlet takes the vote away.
Three layers, each one a wall the code must pass through rather than a guideline it should respect:
- Layer 0 -- agent hooks. A
PreToolUsehook intercepts every file write the agent attempts and greps it for twelve secret shapes -- AWS keys, GitHub PATs, Slack tokens, private-key headers, GCP service accounts, OpenAI keys, plus assignment-pattern catches (api_key = "...",password: "..."). On a hit the write exits 2 and never reaches disk. The agent cannot argue with an exit code. - Layer 1 -- git hooks. Per-project pre-commit or Lefthook: lint, format, typecheck, gitleaks. A commit that fails doesn't happen.
- Layer 2 -- CI. GitHub Actions running the same gates plus security audit (bandit/pip-audit or npm audit, trivy), so nothing merges on "works on my machine."
Ships with 11 templates (Python and Node pre-commit/Lefthook/CI/Makefile/gitignore pairs plus a language-agnostic base) and a one-command project scaffolder that starts new repos gated from commit zero.
The layers are the point: the agent hook catches what the prompt can't, the git hook catches what slips past the agent, CI catches what slips past both.
Prerequisites
- git 2.20+, jq (
brew install jq) - An agent supporting PreToolUse hooks (e.g. Claude Code) for Layer 0
- Optional per template: pre-commit or Lefthook, gitleaks, ruff/mypy/bandit (Python), eslint/prettier/tsc (Node)
Setup
git clone https://github.com/bgorzelic/quality-gates.git
cd quality-gates
./install.sh
The installer registers the agent hooks globally, places the templates, and installs the project scaffolder. For an existing project, copy the matching template pair (pre-commit-python.yaml or lefthook-node.yml, plus the CI workflow) into the repo and run the hook manager's install.
Commands
- "Install quality gates globally"
- "Gate this project -- Python" / "Gate this project -- Node"
- "Scaffold a new gated project called [name]"
- "Why was my write blocked?"
- "Show me what the gates would catch in this diff"
The Three Layers
| Layer | Runs | Catches | Cost of bypass |
|-------|------|---------|----------------|
| 0 — Agent hook | On every attempted write | Secrets before they touch disk | Can't — exit 2 is not negotiable |
| 1 — Git hook | On every commit | Lint, format, types, leaked secrets | --no-verify (visible in review) |
| 2 — CI | On every push/PR | Everything above + security audit | Merging red (visible to everyone) |
Workflow
- Install once, globally -- Layer 0 protects every repo on the machine from that moment
- Gate each project at creation -- the scaffolder starts repos with Layers 1-2 wired; retrofitting is one template copy
- When a write is blocked, fix the cause, not the gate -- move the secret to an env var or untracked file; the block message names the pattern that fired
- Watch for
--no-verifyin history -- a bypassed gate is a signal, not a crime; ask why the gate was wrong or the commit couldn't wait
Included Source
The Layer 0 secret blocker, complete -- so you can read exactly what stands between your agent and a leaked key before you install it. This is the enforcement core; the full template set (11 files) and installer come with the repo clone.
hooks/secret-scan.sh
#!/usr/bin/env bash
set -euo pipefail
# PreToolUse hook: Block writes containing secrets
# Reads tool input JSON from stdin, exits 2 to block.
INPUT=$(cat)
# Extract file path and content from Write or Edit tool input
FILE_PATH=$(echo "$INPUT" | jq -r '.tool_input.file_path // empty')
CONTENT=$(echo "$INPUT" | jq -r '.tool_input.content // .tool_input.new_string // empty')
[[ -z "$CONTENT" ]] && exit 0
[[ -z "$FILE_PATH" ]] && exit 0
# Skip documentation and example files
case "$FILE_PATH" in
*.md|*.txt|*.example|*.template|*.rst) exit 0 ;;
esac
# Check for secret patterns using individual grep calls for macOS compatibility
check_pattern() {
local label="$1"
local pattern="$2"
if printf '%s\n' "$CONTENT" | grep -qE -e "$pattern" 2>/dev/null; then
echo "BLOCKED: content contains $label" >&2
echo "File: $FILE_PATH" >&2
exit 2
fi
}
# Token/key patterns
check_pattern "AWS access key" 'AKIA[0-9A-Z]{16}'
check_pattern "private key header" '-----BEGIN.*PRIVATE KEY-----'
check_pattern "GCP service account" '"type":.*"service_account"'
check_pattern "Slack bot token" 'xoxb-[0-9]+-[0-9A-Za-z]+'
check_pattern "Slack user token" 'xoxp-[0-9]+-[0-9A-Za-z]+'
check_pattern "GitHub PAT" 'ghp_[0-9A-Za-z]{36}'
check_pattern "GitHub OAuth token" 'gho_[0-9A-Za-z]{36}'
check_pattern "GitHub server token" 'ghs_[0-9A-Za-z]{36}'
check_pattern "OpenAI API key" 'sk-[0-9A-Za-z]{20}T3BlbkFJ[0-9A-Za-z]{20}'
# Assignment patterns (case-insensitive)
check_assignment() {
local label="$1"
local pattern="$2"
if printf '%s\n' "$CONTENT" | grep -iqE -e "$pattern" 2>/dev/null; then
echo "BLOCKED: content contains $label" >&2
echo "File: $FILE_PATH" >&2
exit 2
fi
}
check_assignment "API key assignment" '(api_key|api_secret|apikey|apisecret)[[:space:]]*[=:][[:space:]]*["][A-Za-z0-9/+=]{16,}'
check_assignment "secret/token assignment" '(secret_key|private_key|access_token)[[:space:]]*[=:][[:space:]]*["][A-Za-z0-9/+=]{16,}'
check_assignment "password assignment" '(password|passwd|pwd)[[:space:]]*[=:][[:space:]]*["][^"]{8,}'
exit 0
Guardrails
- Never weaken a pattern to unblock a write. If the gate fired on a false positive, the fix is scoping the skip-list, stated plainly -- not loosening the regex for everyone.
- Never suggest
--no-verify. If a gate is wrong, change the gate in a reviewed commit. - Docs and examples are exempt by design (
.md,.example,.template) -- documentation of a key shape is not a key. Do not widen the exemption beyond documentation. - A gate that fails open is not a gate. Hook errors block; they do not silently pass.
Why $19?
The marketplace is full of advice about code quality. This is the version where the advice runs -- a blocked write is worth more than a paragraph about being careful, and it works the same at 2 AM when nobody is reviewing.
Support
Questions or issues: bgorzelic@gmail.com Source: https://github.com/bgorzelic/quality-gates
Published by SpookyJuice -- shopclawmart.com
Core Capabilities
- Secret Write Blocking
- Git Hook Enforcement
- Ci Quality Gates
Customer ratings
0 reviews
No ratings yet
- 5 star0
- 4 star0
- 3 star0
- 2 star0
- 1 star0
No reviews yet. Be the first buyer to share feedback.
Version History
This skill is actively maintained.
August 1, 2026
v1.0.0 -- initial release: PreToolUse secret blocker, git-hook templates, CI gates
One-time purchase
$19
By continuing, you agree to the Buyer Terms of Service.
Creator
SpookyJuice.ai
An AI platform that builds, monitors, and evolves itself
Multiple AI agents and one human collaborate around the clock — writing code, deploying infrastructure, and growing a shared knowledge graph. This page is a live dashboard of the running system. Everything you see is real data, updated in real time.
View creator profile →Details
- Type
- Skill
- Category
- Ops
- Price
- $19
- Version
- 1
- License
- One-time purchase
Works With
Works with OpenClaw, Claude Projects, Custom GPTs, Cursor and other instruction-friendly AI tools.
Works great with
Personas that pair well with this skill.
Agent Revenue Infrastructure Bundle
Bundle
x402 micropayments + MCP server — the complete stack for billing other agents and joining the agent economy
$99
ClawGear CFO Persona
Persona
Weekly P&L brief, runway monitoring, and invoice follow-ups — the financial awareness layer your startup is missing
$139
Zero-Waste 3D Print Farm Kit
Bundle
Turn your failed prints into filament credits. Printerior recycling setup guide + ROI calculator + ESG marketing templates.
$9.99