From: Thanh Ha Date: Thu, 13 Sep 2018 14:19:54 +0000 (-0400) Subject: Move docs reqs back to reqs.txt X-Git-Tag: v0.2.5~1 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=b90afb2021db2a0df6ca33744c2b71b2b00ec7b6;p=releng%2Fdocs-conf.git Move docs reqs back to reqs.txt We actually depend on lfdocs-conf to ship Sphinx to downstream consumers removing it from requirements.txt was a bad idea. Move it back and use skip_install=True in coala to have it skip installing requirements.txt in the coala testenv. Change-Id: Ia0739405a4b68dcdb1ca509701745b6dc9828588 Signed-off-by: Thanh Ha --- diff --git a/.coafile b/.coafile index fe3628c..8a2fa26 100644 --- a/.coafile +++ b/.coafile @@ -27,7 +27,7 @@ bears = BanditBear, PyImportSortBear files = docs_conf/**.py known_first_party_imports = lftools -known_third_party_imports = pytest, six +known_third_party_imports = pytest, six, sphinx_bootstrap_theme pydocstyle_ignore = D203, D213, D301 max_line_length = 120 diff --git a/docs/requirements.txt b/docs/requirements.txt deleted file mode 100644 index e68bd8c..0000000 --- a/docs/requirements.txt +++ /dev/null @@ -1,2 +0,0 @@ -Sphinx~=1.7.9 -sphinx_bootstrap_theme>=0.6.2 diff --git a/docs_conf/conf.py b/docs_conf/conf.py index c27ff24..22a9da0 100644 --- a/docs_conf/conf.py +++ b/docs_conf/conf.py @@ -17,9 +17,8 @@ Configure sphinx-doc through an YAML file. import imp import os.path -import yaml - import sphinx_bootstrap_theme +import yaml def _merge_yaml(x, y): diff --git a/requirements.txt b/requirements.txt index 35aaeb5..1dd7d05 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,4 @@ pytest pyyaml +Sphinx~=1.7.9 +sphinx_bootstrap_theme>=0.6.2 diff --git a/tox.ini b/tox.ini index f8d9dd3..7d46d2b 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -minversion = 1.6 +minversion = 1.9 envlist = check-hooks, coala, @@ -8,8 +8,7 @@ envlist = [testenv] deps = - -rrequirements.txt - -rdocs/requirements.txt + -rrequirements.txt commands = pytest --basetemp={envtmpdir} {posargs} @@ -24,15 +23,16 @@ basepython = python3 deps = coala coala-bears - Sphinx<1.5,>=1.3 nodeenv==1.1.2 commands = nodeenv -p npm install --global write-good + # Workaround for systems that do not have `skip_install` (tox>=1.9) + pip install Sphinx~=1.4.9 coala --non-interactive +skip_install=True [testenv:docs] -deps = -rdocs/requirements.txt commands = sphinx-build -W -b html -n -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/html echo "Generated docs available in {toxinidir}/docs/_build/html"