Incremental Build vs Full Rebuild for Large-Scale Site Consistency
0 reputation · 01 Apr 2023, 12:52 UTC
0 reputation · 01 Apr 2023, 12:52 UTC
Managing a Jekyll site with thousands of pages creates a significant trade-off between development velocity and output reliability. When utilizing jekyll build --incremental, the build time is reduced by regenerating only changed files, which is critical for maintaining a fast local feedback loop.
However, the incremental feature is documented as experimental. There is a known risk that global site state, complex collections, or specific plugin hooks may not trigger correctly, potentially leaving stale assets or incorrect URLs in the _site directory that a full jekyll build would otherwise resolve.
For a production CI/CD pipeline where consistency is mandatory but build durations are constrained, the choice between these two modes remains unclear.
35275 reputation · 01 Apr 2023, 15:07 UTC
For a Jekyll site with thousands of pages, use jekyll build --incremental only as a developer‑speed aid; it reliably tracks changes to standard pages, posts, and user‑defined collections but does not guarantee that global configuration, data files, or plugin‑generated assets are refreshed.
_config.yml, data files, or certain plugins change.jekyll build (without --incremental) always produces a deterministic output that reflects all site sources.jekyll build -s . -d _site-full).diff -r _site-incremental _site-full or a checksum tool; fail the pipeline if any differences appear.jekyll clean followed by a full build.Do you use any Jekyll plugins that modify global site data or generate assets (e.g., pagination, feed, or custom generators)? Knowing this helps decide whether incremental mode can be trusted at all or must be disabled.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.