From 3bb2e50f2cd96c2cfd6b0b4c38a21d683098404b Mon Sep 17 00:00:00 2001 From: Mike Auty Date: Tue, 17 Sep 2019 18:33:58 +0100 Subject: [PATCH] Ensure the autodoc generated files are regenerated each run. --- doc/source/conf.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/doc/source/conf.py b/doc/source/conf.py index 154e3d2aa..dc828ec2e 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -23,6 +23,12 @@ import sphinx.ext.apidoc def setup(app): volatility_directory = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', 'volatility')) + # Ensure autodoc regenerates based on the current tree + for dir, _, files in os.walk(os.path.dirname(__file__)): + for filename in files: + if filename.startswith('volatility.'): + os.unlink(os.path.join(dir, filename)) + sphinx.ext.apidoc.main(argv = ['-e', '-M', '-f', '-T', '-o', 'source', volatility_directory]) # Go through the volatility.framework.plugins files and change them to volatility.plugins