added
This commit is contained in:
1 parent
e1d8deb861
commit
83bb404a94
14 files changed
+292
-18
No files matched your search
@@ -7,7 +7,7 @@ Run after:
|
||||
4. python skills-scripts/build_discovery_files.py
|
||||
|
||||
This script copies files from hugo-html-builder/public into public while
|
||||
preserving repo-level discovery files generated outside Hugo.
|
||||
preserving repo-level discovery files and the Poppy manifest generated outside Hugo.
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
@@ -31,6 +31,8 @@ PRESERVE_AT_PUBLIC_ROOT = {
|
||||
|
||||
|
||||
def should_preserve(relative_path: Path) -> bool:
|
||||
if relative_path.as_posix() == ".well-known/poppy.json":
|
||||
return True
|
||||
return len(relative_path.parts) == 1 and relative_path.name in PRESERVE_AT_PUBLIC_ROOT
|
||||
|
||||
|
||||
@@ -61,7 +63,7 @@ def main() -> None:
|
||||
copied, skipped = copy_hugo_output()
|
||||
print(f"Copied {copied} Hugo output files into {PUBLIC_ROOT}")
|
||||
if skipped:
|
||||
print("Preserved root discovery files:")
|
||||
print("Preserved discovery files:")
|
||||
for path in skipped:
|
||||
print(f"- {path}")
|
||||
|
||||
|
||||
Reference in new issue
Block a user