@@ -29,10 +29,15 @@ This file is intended to be used by an LLM such as Claude.
2929- Handles both formatting and linting
3030- For formatting: ` uv run ruff format . `
3131- For checking: ` uv run ruff check . `
32+ - For auto-fixing: ` uv run ruff check . --fix `
3233- Common issues:
3334 - Line length (default 88 chars)
34- - Import sorting
35+ - Import sorting (I001 errors)
3536 - Unused imports
37+ - When line length errors occur:
38+ - For strings, use parentheses and line continuation
39+ - For function calls, use multiple lines with proper indentation
40+ - For imports, split into multiple lines
3641
3742### Pyright
3843- Type checker
@@ -42,6 +47,18 @@ This file is intended to be used by an LLM such as Claude.
4247 - Optional types need explicit None checks
4348 - String operations need type narrowing
4449
50+ ## Pre-commit Hooks
51+
52+ - Configuration in ` .pre-commit-config.yaml `
53+ - Runs automatically on git commit
54+ - Includes:
55+ - Prettier for YAML/JSON formatting
56+ - Ruff for Python formatting and linting
57+ - When updating ruff version:
58+ - Check available versions on PyPI
59+ - Update ` rev ` in config to match available version
60+ - Add and commit config changes before other changes
61+
4562## Best Practices
4663
47641 . Always check git status and diff before committing
0 commit comments