-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathlefthook.yaml
36 lines (34 loc) · 968 Bytes
/
lefthook.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Global hooks
pre-commit:
parallel: false
piped: true
commands:
1_build:
run: LEFTHOOK_QUIET=meta bun lefthook run build
build:
parallel: true
piped: false
commands:
contracts:
root: packages/contracts
files: git diff --staged --name-only | grep "packages/contracts" || true
glob: "**/*.sol"
run: forge build
subgraph:
root: packages/subgraph
files: git diff --staged --name-only | grep "packages/subgraph" || true
glob: "**/*.{ts,yaml,graphql}"
run: bunx graph build
# frontend:
# root: packages/frontend
# files: git diff --staged --name-only | grep "packages/frontend" || true
# glob: "**/*.{ts,tsx}"
# run: tsc && vite build
commit-msg:
commands:
debug:
run: echo "Commit-msg hook is running" >> debug.log
commitlint:
run: |
echo "Running commitlint" >> debug.log
bunx commitlint --edit $LEFTHOOK_COMMIT_MESSAGE_PATH