Skip to content

Commit 0bb1d1a

Browse files
TMHSDigitalclaude
andcommitted
perf(gallery): link each script instead of inlining it; LF-pin generated files
Detail pages embedded the full syntax-highlighted script (farm-tractor: 419 KB of HTML for a 165 KB script), so committed gallery HTML was 20.6 MB, every script edit rewrote its page, and 274 commits had produced ~5,000 HTML blobs, the largest share of history growth (and of every plugin install, since the plugin source is the repo root). - build_gallery.py: the Source section is now the script path plus a "View the script on GitHub" (blob) link. Removed the build-time tokenize highlighter, the code-view CSS and the collapse/copy JS for it; the #source jump link still resolves. A page no longer changes when only its script does. - All generated files are written with newline="\n", and .gitattributes pins *.html, *.css and *.py to LF, so a Windows checkout without core.autocrlf=true does not trip the drift gate. Measured after regeneration: detail pages median 30 KB, max 48.8 KB (fern-mossy-rock), gallery HTML total 4.59 MB (was 20.6 MB); 134 files, -376k lines. check_site_links on the staged _site: 135 pages, 0 failures; check_gallery_images ok. Closes #343 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 60506e8 commit 0bb1d1a

136 files changed

Lines changed: 413 additions & 376471 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.gitattributes‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
# do not churn gallery.json, plugin.json, or skill files.
33
*.json text eol=lf
44
*.md text eol=lf
5+
# Generated gallery HTML/CSS and Python stay LF too: build_gallery.py writes
6+
# LF, so a Windows checkout with core.autocrlf=false must not see drift.
7+
*.html text eol=lf
8+
*.css text eol=lf
9+
*.py text eol=lf
510

611
# Binary. Gallery stills and any future .blend fixtures.
712
*.webp binary

0 commit comments

Comments
 (0)