Move sphinx-apidoc into conf.py, too.

This commit is contained in:
Todd Gamblin 2016-08-30 21:02:34 -07:00
parent 32834dd67d
commit 3a9388b43a
3 changed files with 7 additions and 1 deletions

View File

@ -1,4 +1,5 @@
package_list.rst
command_index.rst
spack*.rst
modules.rst
_build

View File

@ -74,7 +74,7 @@ clean:
-rm -f package_list.rst command_index.rst
-rm -rf $(BUILDDIR)/* $(APIDOC_FILES)
html: apidoc
html:
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."

View File

@ -42,6 +42,7 @@
import shutil
import subprocess
from glob import glob
from sphinx.apidoc import main as sphinx_apidoc
# -- Spack customizations -----------------------------------------------------
@ -93,6 +94,10 @@
for cmd in sorted(command_names):
index.write(' * :ref:`%s`\n' % cmd)
# Run sphinx-apidoc
sphinx_apidoc(['-T', '-o', '.', '../spack'])
#
# Exclude everything in spack.__all__ from indexing. All of these
# symbols are imported from elsewhere in spack; their inclusion in