-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.lefthook.yml
More file actions
21 lines (20 loc) · 854 Bytes
/
.lefthook.yml
File metadata and controls
21 lines (20 loc) · 854 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
pre-commit:
parallel: true
commands:
############################################################################
#### =====> dotenv hooks <=========================
## Try to git add .env → ❌ blocked
## Try to change .env.template after it’s in the repo → ❌ blocked
## Add new .env.template2 → ✅ allowed (first-time add is okay)
## Try to change .env.template2 later → ❌ blocked
no-env-file:
run: ./.githooks/no-env-file.sh
lock-env-pattern:
run: ./.githooks/lock-env-pattern.sh
############################################################################
## Every time a checkout happens, run this Git command.
post-checkout:
commands:
#### =====> Assume unchanged files <=========================
assume-unchanged-files:
run: ./.githooks/assume-unchanged-files.sh