Debian Codegraph @

.pre-commit-config.yaml

raw
1 ci:
2 autofix_prs: false
3 autoupdate_commit_msg: "pre-commit: bump repositories"
4
5 repos:
6 - repo: https://github.com/pre-commit/pre-commit-hooks
7 rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # frozen: v6.0.0
8 hooks:
9 - id: check-ast
10 - id: check-builtin-literals
11 - id: check-docstring-first
12 - id: check-merge-conflict
13 - id: check-yaml
14 - id: check-toml
15 exclude: tests/packages/test-(bad-syntax|no-permission)/pyproject.toml
16 - id: debug-statements
17 - id: end-of-file-fixer
18 - id: trailing-whitespace
19 - repo: https://github.com/abravalheri/validate-pyproject
20 rev: 4b2e70d08cb2ccd26d1fba73588de41c7a5d50b7 # frozen: v0.25
21 hooks:
22 - id: validate-pyproject
23 - repo: https://github.com/adamchainz/blacken-docs
24 rev: dda8db18cfc68df532abf33b185ecd12d5b7b326 # frozen: 1.20.0
25 hooks:
26 - id: blacken-docs
27 additional_dependencies: [black==25.*]
28 - repo: https://github.com/rbubley/mirrors-prettier
29 rev: "39e2973981e6d2f9b6c543b0086a2d2393abdc89" # frozen: v3.9.4
30 hooks:
31 - id: prettier
32 - repo: https://github.com/LilSpazJoekp/docstrfmt
33 rev: a05381030e526dc863e2006d34824271d7681d08 # frozen: v2.2.0
34 hooks:
35 - id: docstrfmt
36 args: ["-l", "120"]
37 additional_dependencies: ["sphinx>=9.1"]
38 exclude: ^docs/index\.rst$ # https://github.com/LilSpazJoekp/docstrfmt/issues/176
39 - repo: https://github.com/astral-sh/ruff-pre-commit
40 rev: c59bba8fb259db0fec2bbb77ad8ba51ea7341b56 # frozen: v0.15.20
41 hooks:
42 - id: ruff-check
43 args: [--fix, --show-fixes]
44 - id: ruff-format
45 - repo: https://github.com/henryiii/flake8-lazy
46 rev: 5fed9a818f2583f0403aed779bf2b6c9aa8d25f4 # frozen: v0.8.5
47 hooks:
48 - id: flake8-lazy
49 files: ^src/
50 - repo: https://github.com/codespell-project/codespell
51 rev: "2ccb47ff45ad361a21071a7eedda4c37e6ae8c5a" # frozen: v2.4.2
52 hooks:
53 - id: codespell
54 args: ["-L", "sur"]
55 - repo: https://github.com/pre-commit/pygrep-hooks
56 rev: "3a6eb0fadf60b3cccfd80bad9dbb6fae7e47b316" # frozen: v1.10.0
57 hooks:
58 - id: rst-backticks
59 - id: rst-directive-colons
60 - id: rst-inline-touching-normal
61 - repo: https://github.com/zizmorcore/zizmor-pre-commit
62 rev: e3eebf65325ccc992422292cb7a4baee967cf815 # frozen: v1.26.1
63 hooks:
64 - id: zizmor
65 files: "^\\.github"
66 args: [--persona=pedantic]
67 - repo: local
68 hooks:
69 - id: changelog-filenames
70 name: Enforce towncrier fragment filenames
71 files: ^docs/changelog/(?!([0-9]+\.(feature|bugfix|doc|removal|misc)\.rst|template\.jinja2|README\.rst)$).*
72 entry: files in changelog must be valid (N.type.rst)
73 language: fail
74 - repo: https://github.com/henryiii/check-sdist
75 rev: 377c4f639d3c5fd025ee882a22ae243e12bef469 # frozen: v1.5.0
76 hooks:
77 - id: check-sdist
78 args: [--inject-junk]
79 additional_dependencies: [flit-core]