Set up pre-commit with basic hooks (trailing whitespace, end-of-file, large files) and ty for type checking via uvx. Fix type error in test where root.find() could return None. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
22 lines
497 B
YAML
22 lines
497 B
YAML
repos:
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
rev: v5.0.0
|
|
hooks:
|
|
- id: trailing-whitespace
|
|
- id: end-of-file-fixer
|
|
- id: check-yaml
|
|
- id: check-added-large-files
|
|
|
|
- repo: https://github.com/astral-sh/uv-pre-commit
|
|
rev: 0.5.24
|
|
hooks:
|
|
- id: uv-lock
|
|
|
|
- repo: local
|
|
hooks:
|
|
- id: ty-check
|
|
name: ty type check
|
|
entry: uvx ty check
|
|
language: system
|
|
types: [python]
|
|
pass_filenames: false
|