.pre-commit-config.yaml 1.42 KB
Newer Older
zhangwenwei's avatar
zhangwenwei committed
1
repos:
2
  - repo: https://github.com/PyCQA/flake8
zhangwenwei's avatar
zhangwenwei committed
3
    rev: 3.8.3
zhangwenwei's avatar
zhangwenwei committed
4
5
    hooks:
      - id: flake8
6
7
  - repo: https://github.com/PyCQA/isort
    rev: 5.10.1
zhangwenwei's avatar
zhangwenwei committed
8
    hooks:
zhangwenwei's avatar
zhangwenwei committed
9
      - id: isort
zhangwenwei's avatar
zhangwenwei committed
10
  - repo: https://github.com/pre-commit/mirrors-yapf
wuyuefeng's avatar
wuyuefeng committed
11
    rev: v0.30.0
zhangwenwei's avatar
zhangwenwei committed
12
13
14
    hooks:
      - id: yapf
  - repo: https://github.com/pre-commit/pre-commit-hooks
zhangwenwei's avatar
zhangwenwei committed
15
    rev: v3.1.0
zhangwenwei's avatar
zhangwenwei committed
16
17
18
19
20
21
    hooks:
      - id: trailing-whitespace
      - id: check-yaml
      - id: end-of-file-fixer
      - id: requirements-txt-fixer
      - id: double-quote-string-fixer
22
      - id: check-merge-conflict
zhangwenwei's avatar
zhangwenwei committed
23
24
      - id: fix-encoding-pragma
        args: ["--remove"]
zhangwenwei's avatar
zhangwenwei committed
25
26
      - id: mixed-line-ending
        args: ["--fix=lf"]
27
28
29
30
  - repo: https://github.com/codespell-project/codespell
    rev: v2.1.0
    hooks:
      - id: codespell
31
32
33
34
35
36
37
38
39
  - repo: https://github.com/executablebooks/mdformat
    rev: 0.7.14
    hooks:
      - id: mdformat
        args: [ "--number" ]
        additional_dependencies:
          - mdformat-gfm
          - mdformat_frontmatter
          - linkify-it-py
zhangwenwei's avatar
zhangwenwei committed
40
41
42
43
44
  - repo: https://github.com/myint/docformatter
    rev: v1.3.1
    hooks:
      - id: docformatter
        args: ["--in-place", "--wrap-descriptions", "79"]
45
  - repo: https://github.com/open-mmlab/pre-commit-hooks
Tai-Wang's avatar
Tai-Wang committed
46
    rev: v0.2.0  # Use the ref you want to point at
47
48
49
50
    hooks:
      - id: check-algo-readme
      - id: check-copyright
        args: ["mmdet3d"]  # replace the dir_to_check with your expected directory to check