diff --git a/scripts/generate.py b/scripts/generate.py index 3a6d2f0..37b685b 100644 --- a/scripts/generate.py +++ b/scripts/generate.py @@ -20,6 +20,7 @@ EXTENSIONS = [ ] MIN_HIDDEN_HEADLINE_LEVEL = 2 +INDEX_ID = "ea48ec1d-f9d4-4fb7-b39a-faa7b6e2ba95" def load_all(top_dir_relative): top = os.path.abspath(top_dir_relative) @@ -156,6 +157,12 @@ def main(src_top, dest_top): f.write(as_document(render(headline, doc, headlineLevel=0))) files_generated += 1 + if headline.id == INDEX_ID: + index_endpath = os.path.join(dest_top, "index.html") + with open(index_endpath, "wt") as f: + f.write(as_document(render(headline, doc, headlineLevel=0))) + files_generated += 1 + # Update graph, replace document ids with headline ids for headline_data in graph.values(): for link in headline_data['links']: @@ -318,6 +325,7 @@ def as_document(html): return f"""
+