From 426a5ffa8ee6d4141d1b14342d287589389f062a Mon Sep 17 00:00:00 2001 From: Matt Riedemann Date: Tue, 25 Aug 2015 13:08:31 -0700 Subject: [PATCH] Remove doc/source/api and doc/build before building docs doc/source/api and doc/build are build artifacts from building the docs using the tox -e docs target. These are ignored in .gitignore since we don't care about them from build to build - but leaving them around can actually make the docs build fail if modules no longer exist but are still sitting in these directories. So this change just cleans those up each time you run tox -e docs. Closes-Bug: #1488637 Change-Id: I646ae0b77a472c425d23815316e804b09bbe867d --- tox.ini | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tox.ini b/tox.ini index 02ed46631fb7..cdfd48dd12de 100644 --- a/tox.ini +++ b/tox.ini @@ -8,6 +8,7 @@ usedevelop = True # tox is silly... these need to be separated by a newline.... whitelist_externals = bash find + rm install_command = pip install -U --force-reinstall {opts} {packages} setenv = VIRTUAL_ENV={envdir} OS_TEST_PATH=./nova/tests/unit @@ -155,6 +156,7 @@ commands = {posargs} [testenv:docs] commands = + rm -rf doc/source/api doc/build python setup.py build_sphinx bash -c '! find doc/ -type f -name *.json | xargs -t -n1 python -m json.tool 2>&1 > /dev/null | grep -B1 -v ^python' oslo-config-generator --config-file=etc/nova/nova-config-generator.conf