Skip to content
This repository was archived by the owner on Nov 6, 2025. It is now read-only.

Commit ba2169c

Browse files
committed
Fixed download locations and rebuild loop
1 parent 44ad8cc commit ba2169c

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

hooks/zip.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,13 @@ def on_pre_build(config: MkDocsConfig):
3333
base = os.path.dirname(config.config_file_path)
3434
project_name = os.path.basename(base)
3535

36-
archive = f"{config.docs_dir}/download.zip"
36+
archive = f"docs/download/{project_name}.zip"
37+
os.makedirs(os.path.dirname(archive), exist_ok = True)
3738
with ZipFile(archive, "w", ZIP_DEFLATED, False) as f:
3839
for name in os.listdir(base):
3940
# @todo: load ignore patterns from .gitignore
4041
if name == "site":
4142
continue
42-
if name.endswith(".zip"):
43-
continue
4443

4544
# Find all files recursively and add them to the archive
4645
path = os.path.join(base, name)

0 commit comments

Comments
 (0)