-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
101 lines (101 loc) · 3.1 KB
/
.pre-commit-config.yaml
File metadata and controls
101 lines (101 loc) · 3.1 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
# please, regularly run `pre-commit autoupdate`
repos:
- repo: https://github.com/commitizen-tools/commitizen
rev: v4.1.0
hooks:
- id: commitizen
stages: [commit-msg]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-toml
- id: check-yaml
- id: check-merge-conflict
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-case-conflict
- id: check-added-large-files
- id: destroyed-symlinks
# - id: check-json
- id: detect-private-key
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.9.2
hooks:
- id: ruff
args: [--config=./pyproject.toml]
- id: ruff-format
args: [--config=./pyproject.toml]
# - repo: https://github.com/pre-commit/mirrors-mypy # TODO: run mypy as pdm would - currently this is not working
# rev: v1.7.1
# hooks:
# - id: mypy
# additional_dependencies: [types-all, pydantic]
# args: [--config-file=./pyproject.toml]
# files: ^src/
# entry: mypy src/
# pass_filenames: false
# - id: pytest-cov-src-packages
# name: pytest-cov-src-packages
# # language: system
# entry: pdm run test
# types: [python]
# stages: [commit]
# pass_filenames: false
# always_run: true
- repo: https://github.com/codespell-project/codespell
rev: v2.4.0
hooks:
- id: codespell
additional_dependencies:
- tomli
language: python
types: [python]
# - repo: https://github.com/guilatrova/tryceratops
# rev: v2.3.2
# hooks:
# - id: tryceratops
- repo: https://github.com/asottile/pyupgrade
rev: v3.19.1
hooks:
- id: pyupgrade
args: [--py311-plus]
# - repo: https://github.com/jendrikseipp/vulture
# rev: v2.3
# hooks:
# - id: vulture
# - repo: https://github.com/dosisod/refurb # requires python>=3.10
# rev: "v1.25.0"
# hooks:
# - id: refurb
- repo: https://codeberg.org/frnmst/md-toc
rev: "9.0.0"
hooks:
- id: md-toc
args: [-p, "cmark", "-l6"] # CLI options
# - repo: https://github.com/mgedmin/check-manifest
# rev: "0.49"
# hooks:
# - id: check-manifest
# - repo: https://github.com/IamTheFij/docker-pre-commit
# rev: v3.0.1
# hooks:
# - id: docker-compose-check
# files: docker-compose.*.y[a]{0,1}ml$
- repo: https://github.com/abravalheri/validate-pyproject
rev: v0.23
hooks:
- id: validate-pyproject
# - repo: https://github.com/pdm-project/pdm
# rev: 2.22.2
# hooks:
# - id: pdm-export
# # pdm export -o requirements.txt --without-hashes --prod
# args: ["uv", "pip", "compile", "pyproject.toml", "--all-extras", "--upgrade", "--output-file", "requirements-dev.txt"]
# files: ^pdm.lock$
# - repo: https://github.com/pdm-project/pdm
# rev: 2.22.2
# hooks:
# # pdm export -o requirements-dev.txt --without-hashes -G :dev
# - id: pdm-export
# args: ["-o", "requirements-dev.txt", "--without-hashes", "-G", ":dev"]
# files: ^pdm.lock$