3
0

.pre-commit-config.yaml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. exclude: ^tests/data/
  2. repos:
  3. - repo: https://github.com/PyCQA/flake8
  4. rev: 3.8.3
  5. hooks:
  6. - id: flake8
  7. - repo: https://github.com/PyCQA/isort
  8. rev: 5.10.1
  9. hooks:
  10. - id: isort
  11. - repo: https://github.com/pre-commit/mirrors-yapf
  12. rev: v0.30.0
  13. hooks:
  14. - id: yapf
  15. - repo: https://github.com/pre-commit/pre-commit-hooks
  16. rev: v3.1.0
  17. hooks:
  18. - id: trailing-whitespace
  19. - id: check-yaml
  20. - id: end-of-file-fixer
  21. - id: requirements-txt-fixer
  22. - id: double-quote-string-fixer
  23. - id: check-merge-conflict
  24. - id: fix-encoding-pragma
  25. args: ["--remove"]
  26. - id: mixed-line-ending
  27. args: ["--fix=lf"]
  28. - repo: https://github.com/codespell-project/codespell
  29. rev: v2.1.0
  30. hooks:
  31. - id: codespell
  32. - repo: https://github.com/executablebooks/mdformat
  33. rev: 0.7.9
  34. hooks:
  35. - id: mdformat
  36. args: ["--number"]
  37. additional_dependencies:
  38. - mdformat-openmmlab
  39. - mdformat_frontmatter
  40. - linkify-it-py
  41. - repo: https://github.com/myint/docformatter
  42. rev: v1.3.1
  43. hooks:
  44. - id: docformatter
  45. args: ["--in-place", "--wrap-descriptions", "79"]
  46. - repo: https://github.com/asottile/pyupgrade
  47. rev: v2.32.1
  48. hooks:
  49. - id: pyupgrade
  50. args: ["--py36-plus"]
  51. - repo: https://github.com/pre-commit/mirrors-mypy
  52. rev: v0.812
  53. hooks:
  54. - id: mypy
  55. - repo: https://github.com/open-mmlab/pre-commit-hooks
  56. rev: v0.2.0 # Use the ref you want to point at
  57. hooks:
  58. - id: check-copyright
  59. args: ["mim", "tests"]