-
Notifications
You must be signed in to change notification settings - Fork 1
/
.pre-commit-config.yaml
61 lines (56 loc) · 1.53 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
# pre-commit.ci configuration
ci:
autofix_prs: false
autoupdate_branch: 'master'
autoupdate_commit_msg: '[pre-commit.ci] pre-commit autoupdate'
autoupdate_schedule: monthly
# Both of these require external Python libs to be installed in the environment
skip: [pylint, align-python-version]
submodules: false
# pre-commit hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-yaml
name: Check YAML
- id: check-toml
name: Check TOML
- id: destroyed-symlinks
- id: end-of-file-fixer
- id: requirements-txt-fixer
name: Fix requirements.txt
files: ^requirements\.txt$
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- id: check-executables-have-shebangs
- id: check-shebang-scripts-are-executable
- repo: https://github.com/psf/black
rev: 24.10.0
hooks:
- id: black
- repo: https://github.com/PyCQA/bandit
rev: '1.7.10'
hooks:
- id: bandit
args: [-r]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.13.0
hooks:
- id: mypy
- repo: local
hooks:
- id: pylint
name: pylint
entry: pylint
language: python
types: [python]
require_serial: true
- id: align-python-version
name: Align Python Version
entry: invoke
args: [check-dockerfile-python-version]
language: system
files: ^(Dockerfile|.github/workflows/ci_tests.yml|pyproject.toml)$
pass_filenames: false
description: 'Check that the Python version in the Dockerfile, GitHub Actions, and pyproject.toml are aligned.'