.pre-commit-config.yaml 1.39 KB
Newer Older
zhangwenwei's avatar
zhangwenwei committed
1
2
repos:
  - repo: https://gitlab.com/pycqa/flake8.git
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
31
32
33
34
35
36
  - repo: https://github.com/markdownlint/markdownlint
    rev: v0.11.0
    hooks:
      - id: markdownlint
        args: ["-r", "~MD002,~MD013,~MD029,~MD033,~MD034",
              "-t", "allow_different_nesting"]
  - repo: https://github.com/codespell-project/codespell
    rev: v2.1.0
    hooks:
      - id: codespell
zhangwenwei's avatar
zhangwenwei committed
37
38
39
40
41
  - repo: https://github.com/myint/docformatter
    rev: v1.3.1
    hooks:
      - id: docformatter
        args: ["--in-place", "--wrap-descriptions", "79"]
42
  - repo: https://github.com/open-mmlab/pre-commit-hooks
Tai-Wang's avatar
Tai-Wang committed
43
    rev: v0.2.0  # Use the ref you want to point at
44
45
46
47
    hooks:
      - id: check-algo-readme
      - id: check-copyright
        args: ["mmdet3d"]  # replace the dir_to_check with your expected directory to check