chore(ci): Prevent file accumulation in cloudflare-pages branch#3491
Open
dishaprakash wants to merge 5 commits into
Open
chore(ci): Prevent file accumulation in cloudflare-pages branch#3491dishaprakash wants to merge 5 commits into
dishaprakash wants to merge 5 commits into
Conversation
Contributor
|
Note Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported. |
averikitsch
reviewed
Jun 23, 2026
| commit_message: "deploy: docs to root for ${{ steps.get_version.outputs.VERSION }}" | ||
| run: | | ||
| cd $GITHUB_WORKSPACE | ||
| git clone --branch cloudflare-pages https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git cf-pages-root-temp |
Contributor
There was a problem hiding this comment.
Can we use the checkout action?
Contributor
Author
There was a problem hiding this comment.
Updated, also changed the bot to release please for CLA compliance
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the failing Cloudflare Pages CI deployment by preventing the infinite accumulation of old Pagefind search index chunks in the cloudflare-pages branch.
Previously, our deployment step used the actions-gh-pages action with keep_files: true. While this correctly protected older, stable versions of the docs (like v1.5.0), it also prevented Git from deleting stale files in the dev folder. Every time a PR was merged, Pagefind generated hundreds of newly hashed search chunks, which piled up next to the old ones. This caused the dev directory to quietly balloon to over 4,000 files, repeatedly breaking Cloudflare Pages' 20,000 file limit.
Key Changes:
Removed the generic actions-gh-pages deployment step.
Implemented a targeted Git deployment script that pulls the cloudflare-pages branch, explicitly wipes the old dev folder and copies over the fresh build.
Older, stable version directories remain completely untouched.
In the versioned release workflow, the older pagefind search indexes from previous deployments are pruned for the same effect