-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
130 lines (130 loc) · 3.57 KB
/
.pre-commit-config.yaml
File metadata and controls
130 lines (130 loc) · 3.57 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
# Apply to all files without committing:
# pre-commit run --all-files
# Update this file:
# pre-commit autoupdate
minimum_pre_commit_version: 1.15.0
default_language_version:
# Use latest LTS release
node: 22.17.0
repos:
- repo: meta
hooks:
- id: check-useless-excludes
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-illegal-windows-names
- id: check-json
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: check-yaml
- id: debug-statements
- id: destroyed-symlinks
- id: detect-aws-credentials
args: [--allow-missing-credentials]
- id: detect-private-key
- id: end-of-file-fixer
- id: fix-byte-order-marker
- id: forbid-submodules
- id: mixed-line-ending
args: [--fix=lf]
- id: name-tests-test
exclude: ^tests/bot_tests/gameplay_framework\.py$
- id: no-commit-to-branch
- id: requirements-txt-fixer
- id: trailing-whitespace
- repo: https://github.com/sirosen/texthooks
rev: 0.6.8
hooks:
- id: alphabetize-codeowners
- id: fix-ligatures
- id: fix-smartquotes
- id: fix-spaces
- id: forbid-bidi-controls
# Use mirror for `mypyc`-compiled `black`
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 25.1.0
hooks:
- id: black
- repo: https://github.com/rbubley/mirrors-prettier # Use maintained fork of official mirror
rev: v3.6.1
hooks:
- id: prettier
- repo: https://github.com/scop/pre-commit-shfmt
rev: v3.11.0-1
hooks:
- id: shfmt
args: [
--write,
--indent=2,
--case-indent, # Switch cases will be indented.
]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.0
hooks:
- id: ruff-check
args: [--exit-non-zero-on-fix]
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.45.0
hooks:
- id: markdownlint
- repo: https://github.com/adrienverge/yamllint
rev: v1.37.1
hooks:
- id: yamllint
args: [--strict]
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
hooks:
- id: shellcheck
- repo: https://github.com/rhysd/actionlint
rev: v1.7.7
hooks:
- id: actionlint
- repo: https://github.com/zizmorcore/zizmor-pre-commit
rev: v1.9.0
hooks:
- id: zizmor
args:
- --strict-collection
- repo: https://github.com/pypa/dependency-groups
rev: 1.3.1
hooks:
- id: lint-dependency-groups
- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
- id: codespell
additional_dependencies:
# `tomllib` was added to stdlib in Python 3.11
- tomli==2.2.1 ; python_version < "3.11"
- repo: local
hooks:
- id: mypy
name: mypy
language: system
entry: mypy
types:
- python
require_serial: true
- id: pylint
name: pylint
language: system
entry: pylint
types:
- python
require_serial: true
- repo: https://github.com/lycheeverse/lychee
rev: lychee-v0.19.1
hooks:
- id: lychee
# Only run manually because it can have false positives and spurious failures
stages: [manual]