Files
homeprod/.pre-commit-sops.sh
T

8 lines
236 B
Bash
Raw Normal View History

2025-03-22 14:29:48 +01:00
#!/bin/bash
for filename in "$@"; do
2025-09-16 21:22:00 +02:00
if [[ "${filename}" =~ values.ya?ml$ ]] || [[ "${filename}" =~ secrets?.ya?ml$ ]] || [[ "${filename}" =~ .env$ ]]; then
2025-03-22 14:29:48 +01:00
sops -e -i "${filename}"
git add "${filename}"
fi
done