Hi and thank you for reading in on this group.

I'm looking for something which I would call 'RST code insertion'.

For example, if I have the main documentation page have a depth 2 TOC:

.. toctree::
   :maxdepth: 2

   foo/index.rst
   bar/index.rst
   baz/index.rst

And a full contents page with:

.. toctree::

   foo/index.rst
   bar/index.rst
   baz/index.rst

I would expect that I could deduplicate the list of files and use some form 
of include.

I would have an indexes.txt file:

   foo/index.rst
   bar/index.rst
   baz/index.rst

Include it in the main index:

.. toctree::
   :maxdepth: 2

.. include:: indexes.txt
   :rst:

And then the contents:

.. toctree::

.. include:: indexes.txt
   :rst:

I didn't figure out a way to do this kind of thing.

How would you do it?

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to