如何在索引上仅显示文档标题.html



在我的狮身人面像生成的文档中,索引页显示Document titleSection Title链接。

==============
Document Title
==============
Section Title
-----------------

我不希望Section Title显示在索引页面上,

所以我更改了 rst 以使用字幕格式,但它仍然出现在索引页面上。如何解决这个问题?

==============
Document Title
==============
Section Title (Document Subtitle)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

我找到了解决方案,在index.rst上将maxdepth设置为1(之前是2(给出了所需的行为。

.. toctree::
:maxdepth: 1

最新更新