1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 #!/usr/bin/env python3 """Erzeugt vorschau.html aus squarespace-code-block.html. Aufruf aus dem Ordner squarespace-scroll-video: python3 tools/vorschau-erzeugen.py .""" import sys, pathlib d = pathlib.Path(sys.argv[1]) snippet = (d / "squarespace-code-block.html").read_text().replace('"/s/', '"media/') page = """ Scroll-Video Vorschau
IHRE MARKE
""" + snippet + """
Squarespace-Footer · Vorschau
""" (d / "vorschau.html").write_text(page) print("ok", len(page))