On Wed, Nov 6, 2019 at 10:52 PM Jeff Larson wrote:
>
> I would like to have two different toctrees, one for LatexPDF and one for HTML. (For example, the landing page for the HTML documentation shouldn't be the first page of the PDF.)
>
> I have tried to use "..only::" directives within my index.rst file, but now see that this is not supported.
>
>
https://github.com/sphinx-doc/sphinx/issues/2132#issuecomment-159801468
>
> Is there a correct way to have different toctrees in index.rst for PDFs and HTML in Sphinx?
I guess the correct way is to create a new source file with the
desired PDF doctrees and use its name as the first element of the
"latex_documents" configuration value:
http://www.sphinx-doc.org/en/master/usage/configuration.html#confval-latex_documents
> If not, is there a way to configure conf.py to have separate master_docs, one for PDF and one for HTML?
Yes, see above.
cheers,
Matthias