-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
41 lines (36 loc) · 1.06 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
41 lines (36 loc) · 1.06 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
files: 'src/|tests/'
repos:
# pre-commit
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v6.0.0'
hooks:
- id: check-case-conflict
- id: end-of-file-fixer
- id: trailing-whitespace
- id: requirements-txt-fixer
- id: check-yaml
- id: check-json
- id: check-toml
- id: check-xml
# isort
- repo: https://github.com/PyCQA/isort
rev: '7.0.0'
hooks:
- id: isort
args: ["--line-length=88", "--multi-line=3", "--lines-after-imports=2", "--trailing-comma"]
# ruff linter and formatter
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.14.11
hooks:
- id: ruff-check
types_or: [ python, pyi, jupyter ]
args: [ --fix ]
- id: ruff-format
types_or: [ python, pyi, jupyter ]
# ty type-checker (checks the whole project, not just the changed files)
- repo: https://github.com/astral-sh/ty-pre-commit
rev: v0.0.69
hooks:
- id: ty
# the api clients need their optional dependencies to type-check
args: [--extra=api]