-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.pre-commit-config.yaml
74 lines (69 loc) · 2.5 KB
/
.pre-commit-config.yaml
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
---
minimum_pre_commit_version: 3.2.0
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
# renovate: datasource=git-tags depName=https://github.com/pre-commit/pre-commit-hooks depType=devDependencies
rev: cef0300fd0fc4d2a87a85fa2093c6b283ea36f4b # v5.0.0
hooks:
- id: trailing-whitespace
args:
- --markdown-linebreak-ext=md
- id: mixed-line-ending
args:
- --fix=lf
- id: end-of-file-fixer
- id: check-merge-conflict
args:
- --assume-in-merge
- id: check-yaml
- id: check-ast
- id: check-builtin-literals
- id: debug-statements
language_version: python3
- repo: https://github.com/asottile/pyupgrade
# renovate: datasource=git-tags depName=https://github.com/asottile/pyupgrade depType=devDependencies
rev: ce40a160603ab0e7d9c627ae33d7ef3906e2d2b2 # v3.19.1
hooks:
- id: pyupgrade
name: Rewrite code for Py3.9+
args:
- --py39-plus
- repo: https://github.com/PyCQA/isort
# renovate: datasource=git-tags depName=https://github.com/PyCQA/isort depType=devDependencies
rev: c8ab4a5b21bac924d106e3103dd7c979fdd0f9bc # 6.0.1
hooks:
- id: isort
args:
- --py=39
- --profile=black
- --force-single-line
exclude: project/src/\{\{ namespaced_package_path \}\}/__init__.py
- repo: https://github.com/psf/black
# renovate: datasource=git-tags depName=https://github.com/psf/black depType=devDependencies
rev: 8a737e727ac5ab2f1d4cf5876720ed276dc8dc4b # 25.1.0
hooks:
- id: black
name: Autoformat Python code
args:
- --line-length=100
- --target-version=py39
- repo: local
hooks:
- id: nox
alias: lint-tests
name: Lint Tests
language: python
entry: nox -e lint-tests-pre-commit --
files: ^tests/.*\.py$
require_serial: true
additional_dependencies:
# renovate: datasource=pypi depName=nox depType=devDependencies
- nox==2025.2.9
- repo: https://github.com/Mateusz-Grzelinski/actionlint-py
# renovate: datasource=git-tags depName=https://github.com/Mateusz-Grzelinski/actionlint-py depType=devDependencies versioning=pep440
rev: a185be0fd5b45112845b700d91b81050c75579e2 # v1.7.7.23
hooks:
- id: actionlint
additional_dependencies:
# renovate: datasource=pypi depName=shellcheck-py depType=devDependencies
- shellcheck-py==0.10.0.1