2015-05-02 18 views

回答

0

.. 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. 
+0

你的'no.text.rst'和'nohtml.rst'的内容是什么? – xuhdev