Closed shimizukawa closed 9 years ago
From Georg Brandl on 2012-01-29 10:50:19+00:00
The content of the include file will be in the doctree you get for the "source-read" event for the file that used the "include" directive, so I don't think it would be good to raise it twice for the same content.
I'm trying to do a bit of processing on my reStructuredText before it gets converted into a doctree using the source-read event, but the documentation project makes extensive use of the standard docutils ".. include:: /path/to/file.rst" directive.
Unfortunately, the source-read event does not fire when includes are read. Can Sphinx raise this event on include as well? Or is there a better way to do some processing on the rst before it is parsed?