.pre-commit-config.yaml 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. repos:
  2. - repo: https://github.com/PyCQA/flake8
  3. rev: 5.0.4
  4. hooks:
  5. - id: flake8
  6. args: ["--max-line-length=150", "--ignore=E131,E125,W503,W504,E203"]
  7. - repo: https://github.com/PyCQA/isort
  8. rev: 5.11.5
  9. hooks:
  10. - id: isort
  11. - repo: https://github.com/pre-commit/mirrors-yapf
  12. rev: v0.32.0
  13. hooks:
  14. - id: yapf
  15. args: ["--style={based_on_style: google, column_limit: 150, indent_width: 4}"]
  16. - repo: https://github.com/codespell-project/codespell
  17. rev: v2.2.1
  18. hooks:
  19. - id: codespell
  20. args: ['--skip', '*.json']
  21. - repo: https://github.com/pre-commit/pre-commit-hooks
  22. rev: v4.3.0
  23. hooks:
  24. - id: trailing-whitespace
  25. - id: check-yaml
  26. - id: end-of-file-fixer
  27. - id: requirements-txt-fixer
  28. - id: double-quote-string-fixer
  29. - id: check-merge-conflict
  30. - id: fix-encoding-pragma
  31. args: ["--remove"]
  32. - id: mixed-line-ending
  33. args: ["--fix=lf"]
  34. - repo: https://github.com/executablebooks/mdformat
  35. rev: 0.7.9
  36. hooks:
  37. - id: mdformat
  38. args: ["--number", "--table-width", "200"]
  39. additional_dependencies:
  40. - mdformat-openmmlab
  41. - mdformat_frontmatter
  42. - linkify-it-py
  43. - repo: https://github.com/myint/docformatter
  44. rev: v1.3.1
  45. hooks:
  46. - id: docformatter
  47. args: ["--in-place", "--wrap-descriptions", "119"]