Using RestructuredText and Sphinx to include a pre

2019-04-29 09:38发布

I'm trying to make this fragment work:

Version History
---------------

These are the versions over time::

    .. include:: ../../CHANGES.txt 

That is, use the include directive so that a file is included as a block quote. Once inside a block quote, the directive is quoted. I want the contents of the file in a block quote.

Any idea how to do this?

1条回答
Juvenile、少年°
2楼-- · 2019-04-29 10:30

I think the .. literalinclude:: directive should give you what you want.

查看更多
登录 后发表回答