mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
Fixes #645 - Making cross-content linking windows compatible
This commit is contained in:
parent
a2d585084e
commit
2692586abe
2 changed files with 6 additions and 0 deletions
|
|
@ -510,6 +510,9 @@ class StaticGenerator(Generator):
|
|||
for f in self.get_files(
|
||||
os.path.join(self.path, static_path), extensions=False):
|
||||
f_rel = os.path.relpath(f, self.path)
|
||||
# On Windows, make sure we end up with Unix-like paths.
|
||||
if os.name == 'nt':
|
||||
f_rel = f_rel.replace('\\', '/')
|
||||
# TODO remove this hardcoded 'static' subdirectory
|
||||
sc = StaticContent(f_rel, os.path.join('static', f_rel),
|
||||
settings=self.settings)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue