forked from rapidsai/cudf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
93 lines (91 loc) · 3.77 KB
/
.pre-commit-config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# Copyright (c) 2019-2022, NVIDIA CORPORATION.
repos:
- repo: https://github.com/PyCQA/isort
rev: 5.10.1
hooks:
- id: isort
# Use the config file specific to each subproject so that each
# project can specify its own first/third-party packages.
args: ["--config-root=python/", "--resolve-all-configs"]
files: python/.*
exclude: (__init__.py|setup.py)$
types_or: [python, cython, pyi]
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
files: python/.*
# Explicitly specify the pyproject.toml at the repo root, not per-project.
args: ["--config", "pyproject.toml"]
- repo: https://github.com/PyCQA/flake8
rev: 3.8.3
hooks:
- id: flake8
args: ["--config=setup.cfg"]
files: python/.*\.(py|pyx|pxd)$
types: [file]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v0.782'
hooks:
- id: mypy
args: ["--config-file=setup.cfg", "python/cudf/cudf", "python/dask_cudf/dask_cudf", "python/custreamz/custreamz", "python/cudf_kafka/cudf_kafka"]
pass_filenames: false
- repo: https://github.com/PyCQA/pydocstyle
rev: 6.1.1
hooks:
- id: pydocstyle
args: ["--config=setup.cfg"]
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v11.1.0
hooks:
- id: clang-format
files: \.(cu|cuh|h|hpp|cpp|inl)$
types_or: [file]
args: ['-fallback-style=none', '-style=file', '-i']
- repo: local
hooks:
- id: no-deprecationwarning
name: no-deprecationwarning
description: 'Enforce that DeprecationWarning is not introduced (use FutureWarning instead)'
entry: '(category=|\s)DeprecationWarning[,)]'
language: pygrep
types_or: [python, cython]
- id: cmake-format
name: cmake-format
entry: ./cpp/scripts/run-cmake-format.sh cmake-format
language: python
types: [cmake]
# Note that pre-commit autoupdate does not update the versions
# of dependencies, so we'll have to update this manually.
additional_dependencies:
- cmakelang==0.6.13
verbose: true
require_serial: true
- id: cmake-lint
name: cmake-lint
entry: ./cpp/scripts/run-cmake-format.sh cmake-lint
language: python
types: [cmake]
# Note that pre-commit autoupdate does not update the versions
# of dependencies, so we'll have to update this manually.
additional_dependencies:
- cmakelang==0.6.13
verbose: true
require_serial: true
- id: copyright-check
name: copyright-check
# This hook's use of Git tools appears to conflict with
# existing CI invocations so we don't invoke it during CI runs.
stages: [commit]
entry: python ./ci/checks/copyright.py --git-modified-only
language: python
- id: doxygen-check
name: doxygen-check
entry: ./ci/checks/doxygen.sh
files: ^cpp/include/
types_or: [file]
language: system
pass_filenames: false
verbose: true
default_language_version:
python: python3