Closes #670: Allow docutils "standard includes" to be again specified with the `include` directive.

This commit is contained in:
Georg Brandl 2011-05-15 12:58:34 +02:00
parent ef674a20a6
commit 6b6ca70622

View File

@ -347,6 +347,10 @@ class Include(BaseInclude):
def run(self):
env = self.state.document.settings.env
if self.arguments[0].startswith('<') and \
self.arguments[0].endswith('>'):
# docutils "standard" includes, do not do path processing
return BaseInclude.run(self)
rel_filename, filename = env.relfn2path(self.arguments[0])
self.arguments[0] = filename
return BaseInclude.run(self)