-
Notifications
You must be signed in to change notification settings - Fork 183
/
Copy path.pre-commit-config.yaml
43 lines (42 loc) · 1.03 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- id: check-yaml
- id: requirements-txt-fixer
- repo: https://github.com/psf/black
rev: 24.1.0
hooks:
- id: black
name: Format code
exclude: "hadamard_utils.py"
- repo: https://github.com/pycqa/isort
rev: 5.11.5
hooks:
- id: isort
name: Format imports
- repo: https://github.com/MarcoGorelli/absolufy-imports
rev: v0.3.1
hooks:
- id: absolufy-imports
exclude: examples/
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.6.0
hooks:
- id: ruff
args: [ --fix ]
- repo: local
hooks:
- id: format-json
name: Format JSON
language: python
entry: python scripts/format_json.py
files: \.(json)$
args: [
'--indent=4',
'--max-line-length=120'
]