-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
30 lines (28 loc) · 913 Bytes
/
.pre-commit-config.yaml
File metadata and controls
30 lines (28 loc) · 913 Bytes
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
exclude: "lib|media_import|ankiaddonconfig"
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.4
hooks:
- id: ruff-check
args: [ --fix ]
- id: ruff-format
- repo: local
hooks:
- id: no_absolute_imports_from_ankihub
name: no_absolute_imports_from_ankihub
types: [python]
exclude: ^tests/
entry: "from ankihub([.]| import )"
language: pygrep
- id: no_anki_aqt_imports_in_client
name: no_anki_aqt_imports_in_client
types: [python]
files: ^ankihub/ankihub_client/
entry: "^(from|import) (anki|aqt)"
language: pygrep