0
votes

I have been working on setting up auto documentation for my Python files, which are in a large hierarchy of directory structure. I am able to generate rst and html files for all of them with my scripts and by using autodoc module. I was wondering if it is possible to generate rst and html files in the same directory structure/hierarchy of directories as my Python files.

eg., the relative path of my python file is: python/common/element.py; the rst file generated is: python.common.element.rst; and same for html. I want it to form the same directory structure as for py files, like: sphinx/_build/rst/python/common/element.rst & sphinx/_build/html/python/common/element.html

PS: I am working on ubuntu-14.04 and Sphinx-1.6.3

1

1 Answers

0
votes

No. Source and build directories must be separate. See the options to sphinx-build.

You could write a script to post-process the output, moving files from the build directory into another.