-
Notifications
You must be signed in to change notification settings - Fork 89
/
.pre-commit-config.yaml
54 lines (54 loc) · 1.5 KB
/
.pre-commit-config.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_install_hook_types: ["pre-push"]
exclude: '(^docs/themes/hugo-book|^vendor|.*golden$|^\.vale)'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-toml
- id: check-shebang-scripts-are-executable
- id: check-json
- id: check-vcs-permalinks
- id: detect-private-key
exclude: ".*_test.go"
- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
hooks:
- id: codespell
files: "^(docs/content|pkg|test)/.*"
- repo: local
hooks:
- id: test
name: "Unit testing"
entry: make
args: ["test"]
language: system
types: [go]
pass_filenames: false
- id: lint
name: "Linting"
entry: make
args: ["lint"]
language: system
pass_filenames: false
- id: check-generated
name: "Check generated vendor and golden files"
entry: make
args: ["check-generated"]
language: system
types: [go]
pass_filenames: false
- id: shellcheck
name: "Shellcheck"
entry: "shellcheck"
language: system
types: [shell]
- id: gitlint
name: "Gitlint"
entry: "make"
language: system
types: [text]
args: ["gitlint"]
# TODO: add a lint-sh when we have the errors fix