Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Pre Commit Gate

ASecurity

Aggregate a fast, diff-scoped security check before `git commit`/`git push` — secrets/gitignore hygiene, SAST/SCA on changed files, and IaC/Claude-config checks where relevant — into a single go/no-go verdict. Use before committing or pushing, not as a full-repo audit.

8 stars
0 votes
0 copies
0 views
Added 9/19/2026
developmentpythonrustgoreactkubernetesterraformgitapisecurity

Works with

claude codeapimcp

Security Analysis

A100/100

Scanned 9/19/2026

$npx -y skills add jassics/awesome-claude-security --skill pre-commit-gate --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Pre Commit Gate?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Pre Commit Gate
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/jassics-pre-commit-gate/badge)](https://www.skillsdirectory.com/skills/jassics-pre-commit-gate)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: pre-commit-gate
description: >-
  Aggregate a fast, diff-scoped security check before `git commit`/`git push` —
  secrets/gitignore hygiene, SAST/SCA on changed files, and IaC/Claude-config
  checks where relevant — into a single go/no-go verdict. Use before committing
  or pushing, not as a full-repo audit.
---

# Goal

A single **BLOCK** or **PASS** verdict on the current changeset, fast enough to
run before every commit — by aggregating existing scanning skills, not
reimplementing them.

# Steps

1. **Scope to the diff.** Use `git status` / `git diff --cached` (or `git diff`
   if nothing is staged yet) to get the changed-file list. Never widen to a
   full-repo scan here — that's what `sast-sca`/`infrastructure-security` are
   for on demand; this gate only exists because it's fast.
2. **Secrets & gitignore hygiene** — run `infrastructure-security:secrets-management-review`
   scoped to the changed files: hardcoded secrets in the diff, and the
   gitignore-hygiene check (sensitive paths like `.env`, keys, `.claude/`,
   `terraform.tfstate*` actually excluded, and not already tracked via
   `git ls-files`).
3. **SAST** — run `sast-sca:sast-review` on changed code files for unsafe
   methods/APIs, with the safe-pattern fix. For Python/React specifically, also
   note whether `secure-coding:safe-function-lint`'s curated rule pack (and its
   installed git hooks) already cover this changeset — if `secure-coding` isn't
   installed/enforced in this repo, flag that as a gap alongside the findings.
4. **SCA** — if a dependency manifest changed (`package.json`, `requirements.txt`,
   `go.mod`, `pom.xml`, lockfiles, etc.), run `sast-sca:sca-review` for
   outdated/vulnerable libraries and the safe version to move to.
5. **IaC** — if Terraform/CloudFormation/Kubernetes manifests changed, cross-ref
   `infrastructure-security:iac-security-review`.
6. **Claude/agent config** — if `.claude/`, `.mcp.json`, or an agent/skill
   definition changed, cross-ref `claude-config-security:config-security-scan`
   (a misconfigured AI-agent setup is itself an attack surface).
7. **Aggregate.** Any confirmed live secret, or any HIGH+ finding from the above
   → **BLOCK**. Everything else → **PASS with warnings** (list them, don't block).

# Output

Top line: **BLOCK** or **PASS**. Then a verdict table: check · result · blocking
findings (file:line · severity · fix). For BLOCK, give the exact fix per
finding, not just the diagnosis, so the developer can resolve it and re-run
immediately.

# Notes

This is deliberately a thin orchestrator over `sast-sca`, `infrastructure-security`,
and `claude-config-security` — it owns no scanning logic of its own. It's also
the diff-scoped, multi-language, Claude-session-only counterpart to
`secure-coding`'s narrower but *enforced* Python/React git hooks — install both;
this gate catches what the hooks don't cover (other languages, SCA, IaC), and
the hooks catch commits made outside a Claude Code session. Staying
scoped to the diff is the point: a gate that takes minutes gets skipped; a gate
that takes seconds gets run. For anything the diff-scoped pass can't catch
(architecture-level issues, cross-file trust boundaries), that's what a full
`security-architect:security-design-review` or `threat-modeling` pass is for —
this skill is the fast last line, not the only line.

Attribution

jassicsjassics
View sourceSee grades on GitHubMore from jassics →
SSkills Directory ProSkills Directory

Get any skill into Claude in one click.

Download any skill as a ZIP for Claude.ai, Claude Desktop, or .claude/skills. $9/mo.

See Pro

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills Directory ProSkills Directory

Get any skill into Claude in one click.

Download any skill as a ZIP for Claude.ai, Claude Desktop, or .claude/skills. $9/mo.

See Pro

Related Skills

Clean Code

Pragmatic coding standards - concise, direct, no over-engineering, no unnecessary comments

304955 votes

Browser Extension Developer

Use this skill when developing or maintaining browser extension code in the `browser/` directory, including Chrome/Firefox/Edge compatibility, content scripts, background scripts, or i18n updates.

285172 votes

Seo Optimizer

SEO optimization with keyword analysis, readability assessment, technical validation, content quality. Use for search rankings, blog posts, content audits, or encountering keyword density, readability scores, meta tags, schema markup errors.

2222 votes

Google Official Seo Guide

Official Google SEO guide covering search optimization, best practices, Search Console, crawling, indexing, and improving website search visibility based on official Google documentation

1862 votes

Tanstack Start

Build a full-stack TanStack Start app on Cloudflare Workers from scratch — SSR, file-based routing, server functions, D1+Drizzle, better-auth, Tailwind v4+shadcn/ui. Use whenever the user mentions TanStack Start, asks to scaffold a full-stack Cloudflare app with SSR, wants an SSR dashboard, or asks for a React 19 + Cloudflare Workers app with file-based routing and server functions — even if they don't name TanStack Start specifically. No template repo — Claude generates every file fresh per ...

10311 votes
View all in development →