Skip to content
Snippets Groups Projects
Commit c6ec1a8a authored by Peterson, Peter's avatar Peterson, Peter
Browse files

Banning build directory from list of source locations

parent b5305dab
No related branches found
No related tags found
No related merge requests found
......@@ -142,7 +142,14 @@ class SourceLinkDirective(AlgorithmBaseDirective):
"""
Fills the file_lookup dictionary after parsing the source code
"""
env = self.state.document.settings.env
builddir = env.doctreedir # there should be a better setting option
builddir = os.path.join(builddir, "..", "..")
builddir = os.path.abspath(builddir)
for dirName, subdirList, fileList in os.walk(self.source_root):
if dirName.startswith(builddir):
continue # don't check or add to the cache
for fname in fileList:
(baseName, fileExtension) = os.path.splitext(fname)
#strip the dot from the extension
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment