/
.pre-commit-config.yaml
97 lines (88 loc) · 2.3 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
fail_fast: false
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-builtin-literals
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-docstring-first
- id: check-json
exclude: ^.vscode/
- id: check-merge-conflict
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: check-yaml
args: [--allow-multiple-documents]
exclude: >
(?x)^(
deploy/twingate-operator/templates/.*|
deploy/test/golden/.*|
)$
- id: debug-statements
- id: destroyed-symlinks
- id: end-of-file-fixer
exclude: >
(?x)^(
deploy/test/golden/.*|
)$
- id: forbid-new-submodules
- id: mixed-line-ending
args: [--fix=lf]
- id: trailing-whitespace
- repo: local
hooks:
- id: ruff-format
name: ruff-format
entry: poetry run ruff format
language: system
types: [ python ]
require_serial: true
- id: pyupgrade
name: pyupgrade
entry: poetry run pyupgrade
language: system
types: [python]
args: [--py311-plus]
- id: autoflake
name: autoflake
entry: poetry run autoflake
language: system
types: [python]
require_serial: true
- id: isort
name: isort
entry: poetry run isort
language: system
types: [python]
require_serial: true
- id: ruff
name: ruff
entry: poetry run ruff
language: system
types: [ python ]
require_serial: true
- repo: https://github.com/koalaman/shellcheck-precommit
rev: v0.10.0
hooks:
- id: shellcheck
files: ^\.envrc|.*\.sh$
- repo: https://github.com/scop/pre-commit-shfmt
rev: v3.8.0-1
hooks:
- id: shfmt-docker
files: ^\.envrc|.*\.sh$
- repo: https://github.com/markdownlint/markdownlint
rev: v0.12.0
hooks:
- id: markdownlint
exclude: >
(?x)^(
.github/pull_request_template.md|
.github/ISSUE_TEMPLATE/.*
)$
exclude: 'CHANGELOG.md'