Repository navigation
Expand file tree
/
Copy path.pre-commit-hooks.yaml
More file actions
72 lines (65 loc) · 2.41 KB
/
Copy path.pre-commit-hooks.yaml
File metadata and controls
72 lines (65 loc) · 2.41 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
# The `repostyle` hook runs the RSnnn linter; the `repostyle-*` gate hooks wrap
# third-party tools whose versions are pinned here, so a consumer bumps one
# repostyle rev to move the whole suite instead of tracking each tool's own
# hook repo. Each gate reads its own config from the consuming repo -- a
# `[tool.*]` table in pyproject.toml for the Python gates, a `.shellcheckrc` or
# per-hook flags for the shell gates -- so the repo-specific config stays local
# while the tool and its version live here.
- id: repostyle
name: repostyle
entry: repostyle
language: python
types_or: [python, markdown, toml, yaml, shell, java]
- id: repostyle-bandit
name: bandit (via repostyle)
description: Security lint of src/, reading [tool.bandit] from the repo.
entry: bandit -c pyproject.toml -r src
language: python
additional_dependencies: ["bandit[toml]==1.9.4"]
pass_filenames: false
types: [python]
- id: repostyle-vulture
name: vulture (via repostyle)
description: Dead-code scan over the paths in [tool.vulture].
entry: vulture
language: python
additional_dependencies: ["vulture==2.16"]
pass_filenames: false
types: [python]
- id: repostyle-deptry
name: deptry (via repostyle)
description: Dependency hygiene of src/, reading [tool.deptry] from the repo.
entry: deptry src
language: python
additional_dependencies: ["deptry==0.25.1"]
pass_filenames: false
types: [python]
- id: repostyle-interrogate
name: interrogate (via repostyle)
description: Docstring-coverage floor, reading [tool.interrogate] from the repo.
entry: interrogate --config=pyproject.toml
language: python
additional_dependencies: ["interrogate==1.7.0"]
pass_filenames: false
types: [python]
- id: repostyle-codespell
name: codespell (via repostyle)
description: Spell-check, reading [tool.codespell] from the repo.
entry: codespell
language: python
additional_dependencies: ["codespell==2.4.2", "tomli"]
types: [text]
- id: repostyle-shellcheck
name: shellcheck (via repostyle)
description: Static analysis of shell scripts, reading .shellcheckrc from the repo.
entry: shellcheck
language: python
additional_dependencies: ["shellcheck-py==0.11.0.1"]
types: [shell]
- id: repostyle-shfmt
name: shfmt (via repostyle)
description: Shell-script format check, failing on an unformatted file.
entry: shfmt -d -i 2 -ci
language: python
additional_dependencies: ["shfmt-py==4.0.0"]
types: [shell]