You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given the code shown below and a file structure of:
policies/document_1.pdf
policies.html
from staticjinja import Site
if __name__ == "__main__":
staticpaths = [
"policies/",
]
site = Site.make_site(
staticpaths=staticpaths,
)
site.render()
Staticjinja is incorrectly identifying policies.html as a staticfile, whereas only the directory policies and it's subcomponents should be marked as a static file.
The text was updated successfully, but these errors were encountered:
from pathlib import Path
# Create test file
filename = "readme.md"
Path(filename).touch()
staticpaths = ["readme/"]
for path in staticpaths:
assert Path(path).exists() is False
path = Path(filename).as_posix()
# Fails assertion
assert any(path.startswith(Path(sp).as_posix()) for sp in staticpaths) is False
Given the code shown below and a file structure of:
Staticjinja is incorrectly identifying
policies.html
as a staticfile, whereas only the directorypolicies
and it's subcomponents should be marked as a static file.The text was updated successfully, but these errors were encountered: