forked from pydantic/pydantic-ai
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
76 lines (74 loc) · 2.03 KB
/
.pre-commit-config.yaml
File metadata and controls
76 lines (74 loc) · 2.03 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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: no-commit-to-branch # prevent direct commits to the `main` branch
- id: check-yaml
args: ["--unsafe"]
- id: check-toml
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-added-large-files
args:
- --maxkb=1024 # 1MB
- --enforce-all # Allow to run in the whole source code, instead of only the changed files.
exclude: |
(?x)^(
tests/models/cassettes/.*|
tests/cassettes/.*|
uv.lock
)$
- repo: https://github.com/sirosen/texthooks
rev: 0.6.8
hooks:
- id: fix-smartquotes
exclude: "cassettes/"
- id: fix-spaces
exclude: "cassettes/"
- id: fix-ligatures
exclude: "cassettes/"
- repo: https://github.com/codespell-project/codespell
# Configuration for codespell is in pyproject.toml
rev: v2.3.0
hooks:
- id: codespell
args: ["--skip", "tests/models/cassettes/*"]
additional_dependencies:
- tomli
- repo: local
hooks:
- id: clai-help
name: clai help output
entry: uv
args: [run, pytest, "clai/update_readme.py"]
language: system
types_or: [python, markdown]
pass_filenames: false
- id: format
name: Format
entry: make
args: [format]
language: system
types: [python]
pass_filenames: false
- id: lint
name: Lint
entry: make
args: [lint]
types: [python]
language: system
pass_filenames: false
- id: typecheck
name: Typecheck
entry: make
args: [typecheck]
language: system
types: [python]
pass_filenames: false
- id: check-cassettes
name: Check cassettes
entry: uv
args: [run, python, scripts/check_cassettes.py]
language: system
files: ^tests/
pass_filenames: false