-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
168 lines (145 loc) · 4.11 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
fail_fast: false
default_stages: [pre-commit, pre-push]
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: check-yaml
args: [--allow-multiple-documents]
- id: check-toml
- id: end-of-file-fixer
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- id: check-added-large-files
args: ['--maxkb=4096']
- id: check-merge-conflict
- id: check-json
exclude: ^.devcontainer/devcontainer.json$
- id: check-symlinks
- id: mixed-line-ending
exclude: .*\.svg$
- id: check-case-conflict
- repo: https://github.com/pre-commit-ci/pre-commit-ci-config
rev: v1.6.1
hooks:
- id: check-pre-commit-ci-config
- repo: https://github.com/jorisroovers/gitlint
rev: v0.19.1
hooks:
- id: gitlint
name: Git Commit Message Linter
entry: gitlint
types: [gitlint]
language: python
- id: gitlint-ci
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.41.0
hooks:
- id: markdownlint
alias: md
name: Lint Markdown files
entry: markdownlint -f -c .github/linters/markdownlint.yml -i node_modules .
types: [markdown]
language: node
- repo: https://github.com/adrienverge/yamllint
rev: v1.35.1
hooks:
- id: yamllint
name: Lint YAML files
entry: yamllint -c .github/linters/yamllint.yml .
types: [yaml]
language: python
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.5.0
hooks:
- id: ruff
- id: ruff-format
# - repo: https://github.com/codespell-project/codespell
# rev: v2.3.0
# hooks:
# - id: codespell
# exclude: "haystack/data/abbreviations"
# args: ["--toml", "pyproject.toml"]
# additional_dependencies:
# - tomli
- repo: https://github.com/rhysd/actionlint
rev: v1.7.5
hooks:
- id: actionlint-docker
args: ["-ignore", "SC2102"]
# - repo: https://github.com/gitleaks/gitleaks
# rev: v8.19.2
# hooks:
# - id: gitleaks
# name: Scan Secrets
# entry: gitleaks detect --source . -v
- repo: https://github.com/antonbabenko/pre-commit-terraform
rev: v1.96.1
hooks:
- id: terraform_fmt
args:
- --args=-diff
- id: terraform_docs
- id: terraform_tflint
- repo: https://github.com/hadolint/hadolint
rev: v2.12.0
hooks:
- id: hadolint
args:
- --config=.hadolint.yaml
files: 'Dockerfile|Dockerfile.release'
- repo: local
hooks:
- id: dashboard-linter
name: dashboard-linter
entry: leeway run components/dashboard:lint
language: system
pass_filenames: false
files: ^components/dashboard/
- repo: https://github.com/golangci/golangci-lint
rev: v1.61.0
hooks:
- id: golangci-lint
entry: golangci-lint run --fix
types: [go]
language: golang
- repo: local
hooks:
- id: gofumpt
name: gofumpt
entry: gofumpt -l -w .
language: golang
types: [go]
pass_filenames: false
- id: go-mod-tidy
name: go-mod-tidy
entry: go mod tidy -v
language: golang
pass_filenames: false
- id: betteralign
name: betteralign
entry: betteralign -apply ./...
language: system
types: [go]
pass_filenames: false
additional_dependencies: []
- id: nilaway
name: nilaway
entry: nilaway ./...
language: golang
pass_filenames: false
- id: race-test
name: race-test
entry: go build -race cmd
language: golang
pass_filenames: false
# - id: go-test
# name: go-test
# entry: go test `go list ./... | grep -v examples` -coverprofile=coverage.out -covermode=atomic
# language: golang
# pass_filenames: false
# - id: go-vet
# name: go-vet
# entry: go vet -vettool=$(which shadow) -strict
# language: golang
# pass_filenames: false