From 42817c5b87faf25357995d47b0914a85c5309bc3 Mon Sep 17 00:00:00 2001 From: John Bampton Date: Wed, 10 Jun 2026 03:33:17 +1000 Subject: [PATCH] Add pre-commit hook gitleaks secret scanner Gitleaks is a tool for detecting secrets like passwords, API keys, and tokens in git repos, files, and whatever else you wanna throw at it via stdin. https://github.com/gitleaks/gitleaks#pre-commit https://gitleaks.io --- .pre-commit-config.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 40f8d92810..f2b8d2d854 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -22,3 +22,9 @@ repos: - id: trailing-whitespace files: \.(cgi|html|json|md|plist|py|rb|rdf|service|sh|template|ya?ml)$ args: [--markdown-linebreak-ext=md] +- repo: https://github.com/gitleaks/gitleaks + rev: v8.30.1 + hooks: + - id: gitleaks + name: run gitleaks + description: check for secrets with gitleaks