Add docs env to tox
[integration/distribution.git] / tox.ini
1 [tox]
2 minversion = 1.6.0
3 envlist =
4     coala,
5     docs,
6     docs-linkcheck,
7     pep8
8 skipsdist = true
9
10 [testenv:coala]
11 basepython = python3
12 deps =
13     coala==0.11
14     coala-bears==0.11
15     # Requests 2.16 breaks dependencies
16     requests<2.16
17 commands =
18     python3 -m nltk.downloader punkt maxent_treebank_pos_tagger averaged_perceptron_tagger
19     coala --non-interactive
20
21 [testenv:docs]
22 deps = -rdocs/requirements.txt
23 commands =
24     sphinx-build -W -b html -n -W -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/html
25     echo "Generated docs available in {toxinidir}/docs/_build/html"
26 whitelist_externals = echo
27
28 [testenv:docs-linkcheck]
29 deps = -rdocs/requirements.txt
30 commands = sphinx-build -W -b linkcheck -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/linkcheck
31
32 [testenv:pep8]
33 deps =
34     flake8
35 commands = flake8
36
37 [flake8]
38 show-source = True
39 max-line-length = 120
40 # - Select E121, E123, E126, E226, E241, E242 and E704 which are turned OFF
41 #   by default but represent guidelines accepted by us.
42 # - Do not select E133 because it is incompatible with E123 which was
43 #   selected instead.
44 # - It turns out that now all checks except E133 are enabled so the select
45 #   can be simplified to be just "E,W". However a new version could change
46 #   that (select E133 instead of E123) but that should be caught by the
47 #   verify job.
48 select = E,W
49 exclude =
50     .git,
51     .tox,
52     docs/conf.py