1
0

Add gitleaks and custom script to check secrets in commits

Additionally add lefthook to manage git hooks
This commit is contained in:
2025-08-01 13:31:44 +03:00
parent 6cd8d3b14b
commit 16719977c8
2 changed files with 164 additions and 150 deletions

14
lefthook.yml Normal file
View File

@@ -0,0 +1,14 @@
# Refer for explanation to following link:
# https://lefthook.dev/configuration/
templates:
av-hooks-dir: "/home/av/projects/private/git-hooks"
pre-commit:
jobs:
- name: "gitleaks"
run: "gitleaks git --staged"
- name: "check secret files"
run: "python3 {av-hooks-dir}/pre-commit/check-secrets-encrypted-with-ansible-vault.py"