forked from SlinkyProject/slurm-operator
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
141 lines (141 loc) · 3.95 KB
/
.pre-commit-config.yaml
File metadata and controls
141 lines (141 loc) · 3.95 KB
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
---
default_install_hook_types:
- pre-commit
- commit-msg
default_stages:
- pre-commit
fail_fast: true
exclude: .helm_ls_cache|boilerplate\..*|.*\.gen\..*|.*\.gotmpl$
repos:
- repo: local
hooks:
- id: commitlint
name: commitlint
entry: commitlint/commitlint:edge
args:
- --config=commitlint.config.ts
- --edit
- --strict
language: docker_image
pass_filenames: false
stages: [commit-msg]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: check-merge-conflict
- id: check-executables-have-shebangs
- id: check-shebang-scripts-are-executable
- id: check-json
- id: check-yaml
args:
- --allow-multiple-documents
exclude: (config|helm)/.*\.(yaml|yml)
- id: check-symlinks
- id: check-added-large-files
- id: trailing-whitespace
- id: end-of-file-fixer
exclude: helm/.*/README.md$
- id: detect-private-key
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.22
hooks:
- id: mdformat
args:
- --wrap=80
exclude: (\.chglog/.*|helm/.*|.github/ISSUE_TEMPLATE/.*)\.md
additional_dependencies:
- mdformat-toc
- mdformat-tables
- mdformat-gfm-alerts
- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
- id: codespell
args: [--write-changes]
- repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt
rev: 0.2.3
hooks:
- id: yamlfmt
args:
- --mapping=2
- --sequence=4
- --offset=2
exclude: (config|helm)/.*\.(yaml|yml)
- repo: https://github.com/pecigonzalo/pre-commit-shfmt
rev: v2.2.0
hooks:
- id: shell-fmt-go
args:
- -w
- -s
- -l
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.11.0.1
hooks:
- id: shellcheck
args:
- --severity=warning
- repo: https://github.com/tekwizely/pre-commit-golang
rev: v1.0.0-rc.2
hooks:
- id: go-fmt
- id: go-mod-tidy
- id: go-vet-mod
- id: go-build-mod
- repo: local
hooks:
- id: version-match
name: Version Match
entry: make version-match
language: system
require_serial: true
pass_filenames: false
# https://github.com/norwoodj/helm-docs/blob/master/.pre-commit-hooks.yaml
- id: make-helm-docs
name: make-helm-docs
entry: make helm-docs
files: (README\.md\.gotmpl|(Chart|requirements|values)\.yaml)$
language: system
require_serial: true
pass_filenames: false
- id: make-helm-validate
name: Make Helm Validate
entry: make helm-validate
types: [yaml]
files: ^helm/
language: system
pass_filenames: false
# https://github.com/golangci/golangci-lint/blob/main/.pre-commit-hooks.yaml
- id: make-golangci-lint
name: make-golangci-lint
entry: make golangci-lint
types: [go]
language: system
require_serial: true
pass_filenames: false
# https://github.com/golangci/golangci-lint/blob/main/.pre-commit-hooks.yaml
- id: make-golangci-lint-fmt
name: make-golangci-lint-fmt
entry: make golangci-lint-fmt
types: [go]
language: system
require_serial: true
pass_filenames: false
- id: make-manifests
name: Make Manifests
entry: make manifests
types: [go]
language: system
pass_filenames: false
- id: make-generate
name: Make Generate
entry: make generate
types: [go]
language: system
pass_filenames: false
- id: make-generate-docs
name: Make Generate Docs
entry: make generate-docs
language: system
pass_filenames: false
require_serial: true