forked from marius-team/marius
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
85 lines (80 loc) · 1.92 KB
/
tox.ini
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
[tox]
envlist = check_lint
skipsdist = true
[testenv:clean_build]
skip_install = true
commands =
rm -rf docs_build
rm -rf docs_html
rm -rf build
description = Clean up build directories
whitelist_externals =
/bin/rm
/usr/bin/rm
[testenv:build_docs]
deps =
sphinx_autodoc_typehints
sphinx_rtd_theme
breathe
torch
skip_install = true
commands =
mkdir -p docs_build
cmake -Bdocs_build -S./ -DBUILD_DOCS=1
cmake --build docs_build --target Sphinx
rm -rf docs_html
mv docs_build/docs/html docs_html
rm -rf docs_build
description = Build docs with sphinx
whitelist_externals =
/bin/cd
/bin/mv
/bin/mkdir
/bin/rm
/usr/bin/cd
/usr/bin/mv
/usr/bin/mkdir
/usr/bin/rm
/usr/bin/cmake
/usr/local/bin/cmake
[testenv:autoformat]
deps =
black==22.6.0
isort==5.10.1
skip_install = true
commands =
black --extend-exclude third_party --preview .
isort src/python/ examples/ test/ setup.py
bash -c 'find src/cpp/include src/cpp/src src/cpp/python_bindings test/cpp -iname *.h -o -iname *.cpp | xargs clang-format -i'
description = Run black, isort, and clang-format autoformatters.
whitelist_externals =
/bin/find
/bin/xargs
/usr/bin/find
/usr/bin/xargs
/usr/bin/bash
/usr/bin/clang-format
/usr/local/bin/clang-format
/usr/local/bin/bash
[testenv:check_lint]
skip_install = true
deps =
black==22.6.0
flake8==4.0.1
flake8-black==0.3.0
flake8-isort==4.1.1
pep8-naming==0.13.0
commands =
flake8
bash -c 'find src/cpp/include src/cpp/src src/cpp/python_bindings test/cpp -iname *.h -o -iname *.cpp | xargs clang-format --dry-run -Werror'
description = Run flake8 and clang-tidy to check formatting
whitelist_externals =
/bin/find
/bin/xargs
/bin/bash
/usr/bin/find
/usr/bin/xargs
/usr/bin/bash
/usr/bin/clang-format
/usr/local/bin/clang-format
/usr/local/bin/bash