-
Notifications
You must be signed in to change notification settings - Fork 1
/
tox.ini
188 lines (177 loc) · 3.54 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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
[tox]
envlist =
doc,
nb,
py,
sty,
passenv = PYTHONPATH
skip_install = True
skip_missing_interpreters = True
skipsdist = True
[testenv]
description =
Run all unit tests
allowlist_externals =
pytest
setenv =
PYTHONHASHSEED = 0
commands =
pytest {posargs}
[testenv:doc]
description =
Build documentation with Sphinx
allowlist_externals =
sphinx-build
passenv =
EXECUTE_NB
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
PYTHONHASHSEED = 0
commands =
sphinx-build -nW --keep-going -b html docs/ docs/_build/html
[testenv:doclive]
description =
Set up a server to directly preview changes to the HTML pages
allowlist_externals =
sphinx-autobuild
passenv =
EXECUTE_NB
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
PYTHONHASHSEED = 0
commands =
sphinx-autobuild \
--open-browser \
--re-ignore .*/.ipynb_checkpoints/.* \
--re-ignore .*/__pycache__/.* \
--re-ignore .*\.pkl \
--re-ignore .*\.pdf \
--re-ignore .*\.png \
--re-ignore .*\.svg \
--re-ignore .*\.tmp \
--re-ignore docs/_build/.* \
--re-ignore docs/_images/.* \
--re-ignore docs/_static/export/.* \
--re-ignore docs/_static/images/.* \
--re-ignore docs/_static/julia/.* \
--re-ignore docs/_static/polarimetry.pdf \
--re-ignore docs/api/.* \
--re-ignore docs/appendix/export/.* \
--watch docs \
--watch src \
docs/ docs/_build/html
[testenv:docnb]
description =
Execute Jupyter notebooks and build documentation with Sphinx
allowlist_externals =
sphinx-build
passenv =
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
EXECUTE_NB = yes
PYTHONHASHSEED = 0
commands =
sphinx-build -nW --keep-going -b html docs/ docs/_build/html
[testenv:docnb-force]
description =
Execute Jupyter notebooks and build documentation with Sphinx
allowlist_externals =
sphinx-build
passenv =
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
FORCE_EXECUTE_NB = yes
PYTHONHASHSEED = 0
commands =
sphinx-build -nW --keep-going -b html docs/ docs/_build/html
[testenv:linkcheck]
description =
Check external links in the documentation (requires internet connection)
passenv =
EXECUTE_NB
TERM
allowlist_externals =
sphinx-build
commands =
sphinx-build \
--color \
-T \
-b linkcheck \
docs/ docs/_build/linkcheck
[testenv:pdf]
description =
Create documentation as a single PDF file
allowlist_externals =
make
passenv =
EXECUTE_NB
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
PYTHONHASHSEED = 0
changedir = docs
commands =
make latexpdf LATEXOPTS=' -interaction=batchmode'
[testenv:pdfnb]
description =
Execute Jupyter notebooks and create documentation as a single PDF file
allowlist_externals =
make
passenv =
EXECUTE_PLUTO
JULIA_CI
JULIA_DEPOT_PATH
SYMPY_CACHE_DIR
TERM
setenv =
EXECUTE_NB = yes
PYTHONHASHSEED = 0
changedir = docs
commands =
make latexpdf LATEXOPTS=' -interaction=batchmode'
[testenv:jcache]
description =
Inspect Jupyter cache
allowlist_externals =
jcache
setenv =
PYTHONHASHSEED = 0
changedir = docs/_build
commands =
jcache {posargs:notebook list}
[testenv:nb]
description =
Run all notebooks with pytest
allowlist_externals =
pytest
commands =
pytest --nbmake --nbmake-timeout=3600 {posargs:docs}
[testenv:sty]
description =
Perform all linting, formatting, and spelling checks
setenv =
PYTHONHASHSEED = 0
SKIP = pyright
allowlist_externals =
pre-commit
commands =
pre-commit run {posargs} -a