-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
90 lines (83 loc) · 2.4 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
90 lines (83 loc) · 2.4 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
default_stages: [pre-commit]
default_install_hook_types: [pre-commit, commit-msg]
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-ast
language_version: python3.13
- id: check-merge-conflict
- id: check-case-conflict
- id: check-json
- id: check-toml
- id: check-yaml
- id: trailing-whitespace
exclude: ^.*\.(lock)$||^docs\/
- id: end-of-file-fixer
exclude: ^.*\.(lock)$||^docs\/
- id: mixed-line-ending
exclude: ^.*\.(lock)$||^docs\/
- id: detect-private-key
- id: pretty-format-json
args:
[--autofix, --no-sort-keys, "--top-keys=_id,name,type,description"]
- id: no-commit-to-branch
args: [--branch, main]
stages: [commit-msg]
- repo: https://github.com/compilerla/conventional-pre-commit
rev: v2.4.0
hooks:
- id: conventional-pre-commit
stages: [commit-msg]
- repo: https://github.com/ambv/black
rev: 23.7.0
hooks:
- id: black
language_version: python3.13
args: [--target-version, py312]
files: ^src/.*\.py$
exclude: ^src/dmss_api/
- repo: https://github.com/PyCQA/bandit
rev: 1.9.4
hooks:
- id: bandit
args: [-l, --recursive, -x, tests]
files: ^.*\.py$
exclude: ^src/dmss_api/
- repo: https://github.com/hadialqattan/pycln
rev: v2.6.0
hooks:
- id: pycln
args: [--config=pyproject.toml]
exclude: ^src/dmss_api/
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
name: isort (python)
files: ^src/.*\.py$
exclude: ^src/dmss_api/
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
hooks:
- id: mypy
args: [--config-file=pyproject.toml]
exclude: ^src/dmss_api/
additional_dependencies:
- types-cachetools >= 5.2.0
- types-requests >= 2.27.30
- types-ujson >= 5.3.0
- types-redis >= 2.3.21.1
- pydantic >= 1.10.12
- repo: https://github.com/pycqa/flake8
rev: 6.1.0
hooks:
- id: flake8
files: ^src/.*\.py$
exclude: ^src/dmss_api/
args:
- "--verbose"
- "--max-line-length=119"
- "--max-complexity=18"
- "--select=B,C,E,F,W,T4,B9"
- "--ignore=E203,E266,E501,W503"