-
Notifications
You must be signed in to change notification settings - Fork 121
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
108 lines (102 loc) · 2.97 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
108 lines (102 loc) · 2.97 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
---
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/hhatto/autopep8
rev: 'v2.3.2'
hooks:
- id: autopep8
args:
- --recursive
- --in-place
- --aggressive
- --aggressive
- --hang-closing
- --max-line-length=88
- repo: https://github.com/PyCQA/isort
rev: "7.0.0"
hooks:
- id: isort
- repo: https://github.com/pycqa/flake8
rev: "7.3.0"
hooks:
- id: flake8
additional_dependencies:
[
# https://pypi.org/project/flake8-pytest-style/
flake8-pytest-style == 2.2.0,
]
args:
- --config
- .flake8
# The list of directories and files to check - matches flake8
# configuration in setup.cfg, but has a slightly different
# purpose. setup.cfg tells flake8 what to check when called e.g.
# by pre-commit or IDE linter integration, the list below tells
# *pre-commit* to which files to apply flake8 check.
files: >
(?x)^(
bin/.*|
examples/.*|
tests/.*|
did/.*|
setup.py
)$
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: "v6.0.0"
hooks:
- id: end-of-file-fixer
- id: mixed-line-ending
- id: trailing-whitespace
- id: name-tests-test
args:
- --pytest-test-first
exclude: disable_test_trac.py
- repo: https://github.com/pylint-dev/pylint
rev: "v4.0.2"
hooks:
- id: pylint
args:
[
"-rn", # Only display messages
"-sn", # Don't display the score
"--rcfile=.pylintrc", # Link to config file
]
- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
- id: codespell
args: [
# Pass skip configuration as command line arguments rather than in the
# config file because neither cfg nor TOML support splitting this argument
# across multiple lines.
# Globs must match the Python `glob` module's format:
# https://docs.python.org/3/library/glob.html#module-glob
"-I .codespell/ignore_words.txt",
# Write changes in place
"-w",
]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v1.18.2'
hooks:
- id: mypy
exclude: examples/.*|bin/did
additional_dependencies: [
bodhi-client,
feedparser,
google-api-python-client,
gssapi,
koji,
lxml,
nitrate,
oauth2client,
pytest,
python-bugzilla,
requests_gssapi,
tenacity,
types-httplib2,
types-python-dateutil,
types-requests,
types-setuptools,
types-urllib3,
]