-
-
Notifications
You must be signed in to change notification settings - Fork 36
/
Copy pathtox.ini
39 lines (36 loc) · 1.13 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
[tox]
minversion = 4.0
envlist =
py{310,311,312}
codestyle
linkcheck
[testenv]
pass_env =
# A variable to tell tests we are on a CI system
CI
# Custom compiler locations (such as ccache)
CC
# Location of locales (needed by sphinx on some systems)
LOCALE_ARCHIVE
# If the user has set a LC override we should follow it
LC_ALL
skip_install = true
description = Invoke sphinx-build to build the website.
deps =
-r{toxinidir}/requirements.txt
commands =
pip freeze --all --no-input
sphinx-build --color -W --keep-going -b html -d _build/ . _build/html {posargs}
python -c 'import pathlib; print("Documentation available under file://\{0\}".format(pathlib.Path("{toxinidir}") / "_build" / "html" / "index.html"))'
# This does not check the html file links.
[testenv:linkcheck]
commands =
pip freeze --all --no-input
sphinx-build -qqq --color -b linkcheck . _build/html {posargs}
[testenv:codestyle]
description = Run all style and file checks with pre-commit
deps =
pre-commit
commands =
pre-commit install-hooks
pre-commit run --color always --all-files --show-diff-on-failure