What is the correct way to split the source document in Sphinx?
I have a large file, let's call it file1.rst, the structure of which looks like this:
Section 1
*********
Subsection 1
============
Subsection 2
============
Subsection 3
============
Each subsection is very long and the source file becomes unmanageable. I would like to put each subsection in a different source file.
I tried with the directive include:
Section 1
*********
.. include:: subsection1.rst
.. include:: subsection2.rst
.. include:: subsection3.rst
But it gives warnings that the labels in subsection 1.rst are duplicated in section1.rst (not true, the label is only in a sub-folder).
Alternatively, is it possible to change the hierarchy in the TOC directive?
source
share