.pre-commit-config.yaml 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. default_language_version:
  2. python: python3.12
  3. exclude: |
  4. (?x)^(
  5. .devcontainer/devcontainer.json|
  6. .github/contributors.json|
  7. .vscode/launch.json|
  8. CONTRIBUTORS.md|
  9. frontend/.*|
  10. static/.*
  11. )$
  12. repos:
  13. - repo: https://github.com/pre-commit-ci/pre-commit-ci-config
  14. rev: v1.6.1
  15. hooks:
  16. - id: check-pre-commit-ci-config
  17. - repo: https://github.com/pre-commit/pre-commit-hooks
  18. rev: v5.0.0
  19. hooks:
  20. - id: check-added-large-files
  21. - id: check-case-conflict
  22. - id: check-json
  23. - id: check-merge-conflict
  24. - id: check-symlinks
  25. - id: check-toml
  26. - id: end-of-file-fixer
  27. - id: trailing-whitespace
  28. args: [--markdown-linebreak-ext=md]
  29. - repo: https://github.com/rtts/djhtml
  30. rev: '3.0.6'
  31. hooks:
  32. - id: djhtml
  33. entry: djhtml --tabwidth 2
  34. alias: autoformat
  35. - id: djcss
  36. alias: autoformat
  37. - id: djjs
  38. alias: autoformat
  39. - repo: https://github.com/astral-sh/ruff-pre-commit
  40. rev: v0.6.9
  41. hooks:
  42. - id: ruff
  43. args: [--fix, --exit-non-zero-on-fix]
  44. - id: ruff-format
  45. - repo: https://github.com/asottile/reorder-python-imports
  46. rev: v3.14.0
  47. hooks:
  48. - id: reorder-python-imports
  49. - repo: https://github.com/asottile/pyupgrade
  50. rev: v3.18.0
  51. hooks:
  52. - id: pyupgrade
  53. alias: autoformat
  54. args: [--py312-plus]
  55. # - repo: local
  56. # hooks:
  57. # - id: rustywind
  58. # name: rustywind Tailwind CSS class linter
  59. # language: node
  60. # additional_dependencies:
  61. # - rustywind@latest
  62. # entry: rustywind
  63. # args: [--write]
  64. # types_or: [html]
  65. # # exclude: '.*\.min\.css'