-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.pre-commit-config.yaml
55 lines (51 loc) · 1.61 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0 # Use the ref you want to point at
hooks:
# Prevent giant files from being committed.
- id: check-added-large-files
# Check whether files parse as valid Python.
- id: check-ast
# Check for file name conflicts on case-insensitive file-systems.
- id: check-case-conflict
# Check for files that contain merge conflict strings.
- id: check-merge-conflict
# Check for debugger imports and py37+ `breakpoint()` calls in Python source.
- id: debug-statements
# Check JSON file syntax
- id: check-json
# Check TOML file syntax.
- id: check-toml
# Check YAML file syntax.
- id: check-yaml
# Makes sure files end in a newline and only a newline
- id: end-of-file-fixer
exclude_types: [svg]
# Replaces or checks mixed line ending
- id: mixed-line-ending
# Trims trailing whitespace
- id: trailing-whitespace
- id: name-tests-test
args: ['--django']
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.9.6"
hooks:
- id: ruff
types: [file, python]
args: [--fix]
- repo: https://github.com/psf/black
rev: "25.1.0"
hooks:
- id: black
types: [file, python]
args: [--config=./pyproject.toml]
- repo: https://github.com/asottile/blacken-docs
rev: 1.19.1
hooks:
- id: blacken-docs
types: [file, rst]
additional_dependencies: [black]
- repo: https://github.com/abravalheri/validate-pyproject
rev: "v0.23"
hooks:
- id: validate-pyproject