Git Secrets Pre-Commit Scanner

Scan Git diffs for exposed credentials using entropy analysis and regex patterns.

31|4|Updated Apr 6, 2026
One-click install
npx skills add https://github.com/kissrosecicd-hub/agents-evolution --skill git-secrets-pre-commit-scanner
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: Git Secrets Pre-Commit Scanner
Source: https://github.com/kissrosecicd-hub/agents-evolution/tree/main/.agents/skills/git-secrets-precommit-scanner
Command: npx skills add https://github.com/kissrosecicd-hub/agents-evolution --skill git-secrets-pre-commit-scanner

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Prevents hidden credentials from entering codebases by scanning Git diffs for exposed secrets using entropy detection and customizable regex patterns.

Core Features & Use Cases

  • Diff-scoped secret detection using entropy analysis (truffleHog) and user-defined regex patterns.
  • Pre-commit integration and optional GitHub push protection API to block unsafe commits in real time.
  • Suitable for local development, CI pipelines, and security-conscious teams to enforce secret policies.

Quick Start

Install and enable the pre-commit scanner to automatically check diffs before each commit.

Frequently Asked Questions about Git Secrets Pre-Commit Scanner

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I scan git diffs to block secrets before a commit?▼

To block secrets before a commit, scan git diffs using entropy analysis and custom regex patterns. This scanner integrates directly into pre-commit hooks to detect and prevent exposed credentials from entering the local codebase in real time.

What is entropy analysis for detecting exposed credentials in git?▼

Entropy analysis for detecting credentials in git identifies high-randomness strings that typically represent secrets. Combined with user-defined regex patterns, it scans diffs to accurately find hidden credentials before they are committed to the repository.

Can I use this pre-commit scanner in CI pipelines and local development?▼

You can use this pre-commit scanner in both local development and CI pipelines. It scans git diffs across these environments to enforce secret-detection rules consistently, preventing credential exposure throughout the entire development workflow.

Does this git secrets scanner integrate with GitHub push protection API?▼

This git secrets scanner integrates with the GitHub push protection API to block unsafe commits in real time. This integration extends local pre-commit diff scanning to enforce remote secret-detection policies directly during the push workflow.

Do I need truffleHog to scan git diffs for exposed secrets?▼

You need local truffleHog tooling to provide entropy detection when scanning git diffs for exposed secrets. The scanner relies on truffleHog alongside user-defined regex patterns to identify and block credentials before they reach your repository.

What is the best way to enforce secret-detection rules in git workflows?▼

The best way to enforce secret-detection rules in git workflows is combining entropy detection and regex pattern scanning within pre-commit hooks. This approach blocks exposed credentials locally and in CI pipelines before repository insertion.