1
Sphinx文档生成器提供了only
markup。例如,下面将只包括外部文件“唯一”如果HTML生成:狮身人面像文件生成器:“只”不是?
.. only:: html
.. include:: a.rst
但我将如何设置“不仅”?以下似乎不工作,甚至用大括号:
.. only:: not html
.. include:: b.rst
Sphinx文档生成器提供了only
markup。例如,下面将只包括外部文件“唯一”如果HTML生成:狮身人面像文件生成器:“只”不是?
.. only:: html
.. include:: a.rst
但我将如何设置“不仅”?以下似乎不工作,甚至用大括号:
.. only:: not html
.. include:: b.rst
.. only:: not html
应该将其指定为每Sphinx documentation的正确方法。以下作品使用sphinx-build 1.2.2:
.. only:: html
This should be HTML format only.
.. only:: text
This should be text format only.
.. only:: not html
.. include:: nohtml.rst
This should be in everything except HTML.
.. only:: not text
.. include:: notext.rst
This should be in everything except Text.
你的'no.text.rst'和'nohtml.rst'的内容是什么? – xuhdev