diff options
author | Birte Kristina Friesel <derf@finalrewind.org> | 2024-06-15 11:50:38 +0200 |
---|---|---|
committer | Birte Kristina Friesel <derf@finalrewind.org> | 2024-06-15 11:50:38 +0200 |
commit | 8641ee16fd7d42dafb7945183b5dcc2c56ec6826 (patch) | |
tree | 7be5268eb2748bb245f940020d4651b2ad991ee0 /bin | |
parent | e5a19cdece0f1fad76611dc6d06764d471b9d526 (diff) |
fix --cdn on detail pages
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/pyggle | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -943,6 +943,16 @@ if __name__ == "__main__": for thumbnail in thumbnails: with open(f"{base_dir}/share/html_detail_start", "r") as f: detail_html_start = f.read() + if args.cdn: + detail_html_start = detail_html_start.replace( + 'href=".data/css/', f'href="{args.cdn}/css/' + ) + detail_html_start = detail_html_start.replace( + 'src=".data/js/', f'src="{args.cdn}/js/' + ) + detail_html_start = detail_html_start.replace( + "path = '.data/css/'", f"path = '{args.cdn}/css/'" + ) with open(f"{base_dir}/share/html_detail_end", "r") as f: detail_html_end = f.read() for thumbnail in thumbnails: |