2
0

.pre-commit-config.yaml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. default_language_version:
  2. node: system
  3. python: python3
  4. repos:
  5. - repo: https://github.com/astral-sh/ruff-pre-commit
  6. rev: 'v0.1.5'
  7. hooks:
  8. - id: ruff
  9. args: [--fix, --exit-non-zero-on-fix]
  10. - id: ruff-format
  11. - repo: https://github.com/pre-commit/mirrors-prettier
  12. rev: v3.1.0
  13. hooks:
  14. - id: prettier
  15. types_or: [css, scss, javascript, ts, tsx, json, yaml]
  16. additional_dependencies:
  17. # Keep in sync with package.json
  18. - prettier@3.1.0
  19. - repo: https://github.com/pre-commit/mirrors-eslint
  20. rev: v8.56.0
  21. hooks:
  22. - id: eslint
  23. types: [file]
  24. files: \.(js|ts|tsx)$
  25. args: [--report-unused-disable-directives]
  26. additional_dependencies:
  27. # Keep in sync with package.json
  28. - eslint@8.56.0
  29. - '@typescript-eslint/eslint-plugin@6.21.0'
  30. - '@typescript-eslint/parser@6.21.0'
  31. - '@wagtail/eslint-config-wagtail@0.4.0'
  32. - repo: https://github.com/thibaudcolas/pre-commit-stylelint
  33. rev: v15.11.0
  34. hooks:
  35. - id: stylelint
  36. files: \.scss$
  37. additional_dependencies:
  38. # Keep in sync with package.json
  39. - stylelint@15.11.0
  40. - '@wagtail/stylelint-config-wagtail@0.8.0'
  41. - repo: https://github.com/thibaudcolas/curlylint
  42. rev: v0.13.1
  43. hooks:
  44. - id: curlylint
  45. args: ['--parse-only']
  46. - repo: https://github.com/rtts/djhtml
  47. rev: 3.0.6
  48. hooks:
  49. - id: djhtml
  50. - repo: https://github.com/returntocorp/semgrep
  51. rev: v1.40.0
  52. hooks:
  53. - id: semgrep
  54. files: \.py$
  55. args: ['--config', '.semgrep.yml', '--disable-version-check', '--error']