.pre-commit-config.yaml 1.6 KB
Newer Older
Y
Yi Wang 已提交
1
repos:
Y
Yu Yang 已提交
2
-   repo: https://github.com/Lucas-C/pre-commit-hooks.git
Y
Yi Wang 已提交
3
    sha: v1.0.1
Y
Yu Yang 已提交
4 5
    hooks:
    -   id: remove-crlf
L
liaogang 已提交
6
        files: (?!.*third_party)^.*$ | (?!.*book)^.*$
Y
Yu Yang 已提交
7 8
-   repo: https://github.com/PaddlePaddle/mirrors-yapf.git
    sha: 0d79c0c469bab64f7229c9aca2b1186ef47f0e37
Y
Yu Yang 已提交
9
    hooks:
Y
Yi Wang 已提交
10 11
    -   id: yapf
        files: (.*\.(py|bzl)|BUILD|.*\.BUILD|WORKSPACE)$
Y
Yu Yang 已提交
12
-   repo: https://github.com/pre-commit/pre-commit-hooks
Y
Yi Wang 已提交
13
    sha: 5bf6c09bfa1297d3692cadd621ef95f1284e33c0
Y
Yu Yang 已提交
14 15 16 17 18
    hooks:
    -   id: check-added-large-files
    -   id: check-merge-conflict
    -   id: check-symlinks
    -   id: detect-private-key
L
liaogang 已提交
19
        files: (?!.*third_party)^.*$ | (?!.*book)^.*$
Y
Yu Yang 已提交
20
    -   id: end-of-file-fixer
L
test  
liaogang 已提交
21
-   repo: local
Y
Yu Yang 已提交
22
    hooks:
23
    -   id: clang-format-with-version-check
L
test  
liaogang 已提交
24 25
        name: clang-format
        description: Format files with ClangFormat.
H
hedaoyuan 已提交
26
        entry: bash ./.clang_format.hook -i
L
test  
liaogang 已提交
27
        language: system
L
liaogang 已提交
28
        files: \.(c|cc|cxx|cpp|cu|h|hpp|hxx|proto)$
Y
Yi Wang 已提交
29 30 31 32 33 34 35 36
-   repo: local
    hooks:
    -   id: cpplint-cpp-source
        name: cpplint
        description: Check C++ code style using cpplint.py.
        entry: bash ./tools/codestyle/cpplint_pre_commit.hook
        language: system
        files: \.(c|cc|cxx|cpp|cu|h|hpp|hxx)$
37
-   repo: https://github.com/PaddlePaddle/pre-commit-golang
38
    sha: 8337620115c25ff8333f1b1a493bd031049bd7c0
W
wuyi05 已提交
39
    hooks:
40 41 42
    -   id: go-fmt
        types:
        - go
D
dzhwinter 已提交
43 44 45 46 47 48 49 50
-   repo: local
    hooks:
    -   id: copyright_checker
        name: copyright_checker
        entry: python ./.copyright.hook
        language: system
        files: \.(c|cc|cxx|cpp|cu|h|hpp|hxx|proto|py)$
        exclude: (?!.*third_party)^.*$ | (?!.*book)^.*$