-
Notifications
You must be signed in to change notification settings - Fork 0
/
lefthook.yml
40 lines (37 loc) · 1.06 KB
/
lefthook.yml
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
37
38
39
40
---
# Configuration for lefthook itself
assert_lefthook_installed: true
colors: true
no_tty: false
output:
- meta # Print lefthook version
- summary # Print summary block (successful and failed steps)
- empty_summary # Print summary heading when there are no steps to run
- success # Print successful steps
- failure # Print failed steps printing
- execution # Print any execution logs (but prints if the execution failed)
- execution_out # Print execution output (but still prints failed commands output)
- execution_info # Print `EXECUTE > ...` logging
- skips # Print "skip" (i.e. no files matched)
source_dir: .lefthook/
# Command groups
lint:
commands:
hadolint:
glob: "*Dockerfile*"
run: hadolint {staged_files}
shellcheck:
glob: "*.sh"
run: shellcheck {staged_files}
parallel: true
# format:
# commands: {}
# Hooks
pre-commit:
commands:
1_lint:
run: lefthook run lint
# 2_format:
# run: lefthook run format
# stage_fixed: true
piped: true