mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2026-09-03 20:52:55 -05:00
The `include` directive now supports absolute paths, which are interpreted as relative to the source directory.
This commit is contained in:
@@ -10,6 +10,8 @@ Test file and literal inclusion
|
||||
|
||||
.. include:: subdir/include.inc
|
||||
|
||||
.. include:: /subdir/include.inc
|
||||
|
||||
.. literalinclude:: literal.inc
|
||||
:language: python
|
||||
|
||||
|
||||
@@ -13,3 +13,6 @@ Absolute :download:`/img.png` download.
|
||||
|
||||
.. absolute image filename
|
||||
.. image:: /img.png
|
||||
|
||||
.. absolute include filename
|
||||
.. include:: /test.inc
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
.. This file is included from subdir/includes.txt.
|
||||
|
||||
This is an include file.
|
||||
Reference in New Issue
Block a user