Skip to content

chore(docs): move Pages site to a separate repo and purge generated history #4878

Closed

Description

@zackees

Context

A recent git pull fetched 103,333 objects (99.54 MiB). The default fetch refspec includes every branch, including gh-pages. The specific master range visible in the screenshot (6062bee6f2..f9774576ec) contributes only 29 commits and ~169 KB of reachable objects; the local remote-tracking reflogs identify the corresponding Pages update; measured attribution is below.

On 2026-10-21, gh-pages held 126,585 files / 875.5 MiB uncompressed, including 126,429 generated files / 874.0 MiB under docs/. Objects reachable from gh-pages but not master total ~501 MB on disk. The latest Pages deployment changed 29,222 paths and introduced ~15.9 MB of reachable objects. The local repository has 1.22 GiB of packs. gh-pages2 also exists (last commit 2025-03-28; ~11 MB beyond master).

GitHub Pages currently serves fastled.io from gh-pages at /. That branch contains 156 non-docs/ files, including CNAME and site assets. .github/workflows/docs2.yml publishes generated Doxygen HTML into its docs/ directory; the workflow explicitly warns that docs are not the only content in the branch. Deleting docs/ with a normal commit would leave old objects in reachable history.

Measured baseline (2026-10-21)

Two fresh, complete downloads from GitHub, with no checkout or shallow/filter options:

Fetch scope Objects Pack bytes Pack MiB
All branches and tags 653,245 671,433,494 640.33
Same branches and tags, excluding gh-pages and gh-pages2 166,643 142,484,346 135.88
Reduction 486,602 (74.49%) 528,949,148 (78.78%) 504.45

Verified that all 552 remaining branch/tag refs have identical names and commit IDs between the downloads. Both repositories report --is-shallow-repository=false. Byte counts sum the received .pack files, excluding index files, working trees, and HTTP framing. This measures avoiding Pages reachability without requiring a rewrite of master; an actual migration still needs the deployment/ref cleanup and server storage verification described above. Wall times were 275.3 s and 67.2 s respectively, but the downloads overlapped and shared bandwidth, so those are observations rather than a controlled speed benchmark.

The specific pull in the screenshot is also attributable through local reflogs:

  • At 2026-10-21 11:57:18 -07:00, origin/gh-pages advanced from 06442ca365ae56a73e6bb05d47e6a8ddb28180b4 to 2c2c9e489231912576eed208caeeed1a3392792f.
  • That range introduced 102,267 objects, or 98.97% of the screenshot's 103,333 received objects. Those objects occupy 102,071,326 bytes / 97.34 MiB in the existing local packs. Stored object bytes are not an exact accounting of the original network pack because delta encoding may differ.
  • git diff --no-renames --name-only OLD NEW reports 104,142 changed paths, all under docs/.
  • The corresponding master range introduced 524 objects / 169,427 stored bytes (165.46 KiB).

The earlier checkout-based measurements were made in a shallow working repository. The fresh-download comparison above provides the complete-history baseline.

Reproduction (use empty scratch destinations):

git clone --bare https://github.com/FastLED/FastLED.git full.git
git init --bare without-pages.git
git --git-dir=without-pages.git fetch https://github.com/FastLED/FastLED.git \
  '+refs/heads/*:refs/heads/*' '^refs/heads/gh-pages' '^refs/heads/gh-pages2' \
  '+refs/tags/*:refs/tags/*'
# Compare count-objects -v and the sum of objects/pack/*.pack file sizes.
# Compare for-each-ref for refs/heads and refs/tags, excluding the two pages refs.

Proposal

  1. Move the entire current Pages site tree, including the root site, assets, CNAME, and generated API reference, into a separate FastLED repository. Preserve the current domain and /docs URLs. Decide whether old site revisions belong in that repository or in an archival bundle outside the main repo.
  2. Change the existing docs publishing workflow to deploy to the new repository with scoped credentials. Reconfigure Pages and verify a release or manual deployment updates the live site.
  3. After cutover, delete gh-pages and obsolete gh-pages2 from FastLED/FastLED. Audit branches, tags, PR refs, and release tooling for remaining reachability. Coordinate a targeted destructive rewrite if generated objects remain reachable. Document clone recovery, and arrange GitHub-side garbage collection/support if needed; deleting refs or running local git gc does not guarantee immediate server reclamation.
  4. Compare fresh-clone/fetch transfer, object counts, and repository size before and after. A narrower local fetch refspec is an interim mitigation, not the migration.

Acceptance criteria

  • Capture reproducible pre-change clone/fetch metrics and an isolated Pages contribution; repeat the measurement after migration and show improvement (RED → GREEN evidence for the large-pull report).
  • fastled.io and fastled.io/docs serve the expected content from the new repository, and a new docs deployment updates it.
  • No workflow publishes generated docs to this repository; gh-pages and, if unused, gh-pages2 are deleted after cutover, with all retaining refs audited.
  • Record deleted/rewritten refs, verified server-side reclamation, and recovery steps for existing clones. A fresh default clone/fetch no longer transfers generated documentation history.

Decisions

  • P2: pulls succeed, but transfer and storage cost are already large and grow with deployments.
  • Move the whole site tree: gh-pages is the live Pages source and contains more than generated docs.
  • Remove both Pages branches after cutover: gh-pages2 appears obsolete, subject to the consumer audit.
  • Permit targeted history rewriting: the requester explicitly authorizes it; measure reachability first and avoid rewriting master unless necessary.

Open questions

  • Which refs besides the Pages branches retain generated content after branch deletion? Resolve with a mirror/ref audit before selecting rewrite commands.

Activity

  1. zackees commented on Oct 21, 2026

    @zackees
    MemberAuthor

    The new release-driven publisher is live in FastLED/dox, configured with GitHub Pages from Actions:

    This completes the separate publisher setup. Cutover of the existing fastled.io site, retirement of the original publisher, and the branch/ref cleanup remain tracked here.

  2. zackees commented on Oct 21, 2026

    @zackees
    MemberAuthor

    Migration completed on 2026-10-21.

    • Reference: https://fastled.github.io/dox/. FastLED/dox#3 explicitly checks out refs/tags/<release> and rejects generation unless HEAD equals the peeled tag commit. The deployed 3.10.8 marker matches d7402f1294e4548d9f8317f76afad37afaddb237 exactly.
    • The daily job only checks for a new stable release; unchanged releases skip both build and deployment. Generated HTML is deployed through Pages artifacts, without Git commits.
    • Documentation inputs are the tagged code API, root README, and the README's directly linked local Markdown. Unlinked provenance files and development journals are excluded; further Markdown links point to GitHub at the same tag. Verified the unwanted sidebar entries are absent and API navigation, namespace pages, search, and CSS still work.
    • Main repo PR #4880 removed docs2.yml, its release dispatch, and unused ci/docs.py; README and issue-template links point to dox. Source Doxyfile/style assets remain available to release builds. Main CI passed; old workflow state is deleted.
    • Website PR #7 migrated the 156 non-documentation site files into the existing website repository, retaining its newer PaletteKnife fixes. fastled.io now uses that repository's Pages deployment. Production homepage, blog, tool assets, docs landing, and deep-link handler pass content checks; www also resolves correctly. DNS changes were unnecessary.
    • fastled.io/docs/ redirects to dox. Legacy /docs/... paths redirect browsers to the corresponding new paths, preserving queries/fragments, using a custom 404 page (the HTTP response remains 404 for these deep-link redirects).
    • Deleted FastLED/FastLED branches gh-pages and gh-pages2. The main repository's old Pages site is now unpublished. A ref audit found no remaining source branch/tag ancestry retaining the old Pages commits, so a rewrite of master was unnecessary.

    Measured after actual cleanup

    A fresh complete bare clone from GitHub, fetching its default branches/tags, contains 166,686 objects and 142,530,420 pack bytes (135.93 MiB). The pre-migration clone measured 653,245 objects and 671,433,494 bytes (640.33 MiB): 78.77% less download data. Confirmed both Pages branches and their old tip objects are absent; the clone is not shallow. Small source-ref changes occurred between measurements.

    Existing checkouts can use git fetch --prune to remove stale remote refs. Their existing packs may retain old objects; a fresh clone obtains the measured smaller repository. GitHub's physical storage reclamation/retention of cached or hidden objects is not observable here; these measurements verify removal from normal clone/fetch reachability.

    Production documentation deployment: https://github.com/FastLED/dox/actions/runs/39686471412 (success).
    Final unchanged-release check: https://github.com/FastLED/dox/actions/runs/39687083897.

  3. moved this from Triage to Done in FastLED Trackeron Oct 21, 2026
  4. zackees commented on Oct 21, 2026

    @zackees
    MemberAuthor

    Follow-up implementation and verification:

    • Scheduled check maintenance: fix: maintain release polling and repair unavailable links dox#4 adds a meaningful monthly release-check.json audit on an isolated orphan branch, automation/release-checks. The first workflow created only that JSON file and advanced repository pushed_at; subsequent checks kept the audit SHA unchanged. Daily checks still compare release identity before deciding to publish. Audit writes use job-scoped contents: write and non-force branch updates.
    • Release README rendering: fix: maintain release polling and repair unavailable links dox#4, WS2801 Timing issue - Calling FastLED.show() too quickly does not update the LEDs. #6, and Support P9813 - AKA Total Lighting Control from CoolNeon #7 annotate files absent from the release rather than publishing broken links, retain exact-tag source links, and render the README-linked guides as readable pages. A clean real-release rendering audit covers all 12 selected Markdown documents and 47 unavailable-file occurrences. Tag 3.10.8 remains pinned to d7402f1294e4548d9f8317f76afad37afaddb237.
    • Doxygen reliability: fix: avoid parallel Doxygen heap corruption dox#5 uses serial processing after two hosted crashes and a local debugger reproduction of heap corruption in the six-worker HTML generator. A hosted full build succeeded afterward.
    • Local storage cleanup: Git pack storage in the existing checkout dropped from 629.90 MiB to 138.49 MiB. The final unique object set exactly matches the 168,941 retained objects from the reachability audit. Every ref, reflog, index, HEAD, and config was preserved; 375 unrelated recoverable commits remain protected in a keep-pack. Full object integrity and rebuilt commit-graph verification both pass. Obsolete documentation objects are gone from this checkout.
    • HTTP redirect cutover remains pending: chore: prepare HTTP documentation redirects fastled-fastled.github.io#8 contains validated Vercel routing configuration and preview/DNS/TLS/rollback instructions. The current legacy deep links still return HTTP 404 with browser redirects. Completing actual HTTP 308 redirects requires Vercel hosting and Gandi DNS access, neither of which is connected in this session. This item is not complete.

    Final production evidence:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions