Skip to content

chore: Starlight → Nimbus migration cleanup#32203

Merged
mvvmm merged 9 commits into
productionfrom
remove-starlight-ci
Jul 21, 2026
Merged

chore: Starlight → Nimbus migration cleanup#32203
mvvmm merged 9 commits into
productionfrom
remove-starlight-ci

Conversation

@mvvmm

@mvvmm mvvmm commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Summary

Completes the Starlight → Nimbus migration by removing all migration scaffolding and making Nimbus the standard build.

CI (ci.yml, publish-production.yml):

  • Removed old Starlight build job, publish-preview job, and link-validation steps
  • Removed nimbus-preview-deploy.yml (stable preview environment used during migration, now redundant)
  • Renamed nimbus-buildbuild, publish-nimbus-previewpublish-preview
  • Removed BUILD_TARGET: nimbus env var — no longer needed
  • Renamed cache keys/paths: astro-nimbus-assetsastro-assets, .astro-cache-nimbus.astro-cache
  • Renamed build artifact: dist-nimbusdist

astro.config.ts:

  • Removed isNimbus conditional and all Starlight-only code (307 → 43 lines)
  • Now imports markdown, integrations, and vite directly from src/nimbus/astro-config.ts

Wrangler configs:

  • Deleted wrangler.nimbus-preview.json; wrangler.preview.json is now the sole preview config
  • Updated wrangler.jsonc and wrangler.preview.json to point to dist instead of dist-nimbus

Other:

  • worker/index.ts and worker/index.preview.ts redirects imports updated to ../dist/__redirects
  • package.json renamed from cloudflare-docs-starlight to cloudflare-docs
  • Removed dist-nimbus from tsconfig.json and src/nimbus/tsconfig.json excludes
  • Stale migration comments cleaned up throughout

@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
/.github/ @cloudflare/content-engineering, @kodster28, @mvvmm, @colbywhite, @ahaywood, @MohamedH1998
* @cloudflare/product-owners
*.ts @cloudflare/content-engineering, @kodster28
package.json @cloudflare/content-engineering
*.astro @cloudflare/content-engineering, @kodster28
/src/components/ @cloudflare/content-engineering, @kodster28
/src/components/realtimekit/ @cloudflare/realtime, @cloudflare/RealtimeKit, @roerohan, @ravindra-cloudflare, @cloudflare/product-owners
*.js @cloudflare/content-engineering, @kodster28
/src/util/api.ts @cloudflare/content-engineering, @kodster28

@mvvmm mvvmm changed the title chore: remove Starlight build jobs from CI chore: complete Starlight → Nimbus migration cleanup Jul 21, 2026
@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

@mvvmm
mvvmm marked this pull request as ready for review July 21, 2026 15:37
@cloudflare-docs-bot

cloudflare-docs-bot Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Review

⚠️ 3 warnings, 💡 1 suggestion found in commit 11972d1.

Fix in your agent
Fix the following review findings in PR #32203 (https://github.com/cloudflare/cloudflare-docs/pull/32203).

Before making changes, review each finding and present a brief summary table:
- For each finding, state whether you agree, disagree, or need clarification
- If you disagree (e.g. the fix requires disproportionate effort for minimal benefit,
  or the finding is factually incorrect), explain why
- If you need clarification before deciding, ask those questions
- Then share your plan for which issues to tackle and in what order

After triaging, fix all legitimate findings. For any you decide to skip,
post a comment on this PR with the finding ID and your reasoning.

---

## Code Review

### Warnings (2)

#### CR-f5d555a92aac · Nimbus output directories not ignored by dev watcher
- **File:** `astro.config.ts` line 38
- **Issue:** Line 38 removed `**/dist-nimbus/**` and `**/.astro-cache-nimbus/**` from `vite.server.watch.ignored`, but `.gitignore` still lists both directories so they can persist in local checkouts. The Vite dev server will enumerate these stale build/cache directories, causing slow startup and extra memory use.
- **Fix:** Continue ignoring `dist-nimbus/` and `.astro-cache-nimbus/` until those entries are removed from `.gitignore` and the directories are no longer expected locally, or delete the stale directories and their `.gitignore` entries as part of this cleanup.

#### CR-eff38308ceed · Unvalidated input in formatBytes
- **File:** `scripts/optimize-svgs.ts` line 4
- **Issue:** formatBytes computes Math.log(bytes) and indexes sizes[i] without handling negative values. It is called with originalSize - optimizedSize, which can be negative if SVGO increases an SVG's size, causing NaN/undefined in the final log.
- **Fix:** Guard against negative bytes or clamp to zero before indexing sizes and computing Math.log.

### Suggestions (1)

#### CR-083f45bcec5f · Leftover dead code after migration
- **File:** `src/scripts/footnotes.ts` line 1
- **Issue:** This file now imports from nimbus, but the only known consumer was `src/components/overrides/Head.astro`, which no longer exists on the `remove-starlight-ci` branch. `src/nimbus/scripts/footnotes.client.ts` already provides the same footnote tooltip behavior for Nimbus, and `src/nimbus/layouts/BaseLayout.astro` loads it.
- **Fix:** Delete `src/scripts/footnotes.ts`; keeping it adds a stray dependency on Nimbus internals and duplication with the Nimbus footnotes client script.

---

## Conventions

### Warnings (1)

#### CV-29e2c2242d93 · Scope accuracy
- **File:** PR-level finding
- **Issue:** The PR removes hundreds of legacy source files across src/components, src/pages, src/plugins, src/schemas, src/styles, src/util, bin/, and others, but the description only discusses CI workflows, astro.config.ts, Wrangler configs, worker redirects, package.json, and tsconfig excludes.
- **Fix:** Add a section summarizing the wholesale deletion of legacy Starlight source directories (components, pages, plugins, schemas, styles, utilities, etc.).

Code Review

This code review is in beta and may not always be helpful — use your judgment.

Warnings (2)
File Issue
astro.config.ts line 38 Nimbus output directories not ignored by dev watcher — Line 38 removed \*\*/dist-nimbus/\*\* and \*\*/.astro-cache-nimbus/\*\* from vite.server.watch.ignored, but .gitignore still lists both directories so they can persist in local checkouts. The Vite dev server will enumerate these stale build/cache directories, causing slow startup and extra memory use. Fix: Continue ignoring dist-nimbus/ and .astro-cache-nimbus/ until those entries are removed from .gitignore and the directories are no longer expected locally, or delete the stale directories and their .gitignore entries as part of this cleanup.
scripts/optimize-svgs.ts line 4 Unvalidated input in formatBytes — formatBytes computes Math.log(bytes) and indexes sizes[i] without handling negative values. It is called with originalSize - optimizedSize, which can be negative if SVGO increases an SVG's size, causing NaN/undefined in the final log. Fix: Guard against negative bytes or clamp to zero before indexing sizes and computing Math.log.
Suggestions (1)
File Issue
src/scripts/footnotes.ts line 1 Leftover dead code after migration — This file now imports from nimbus, but the only known consumer was src/components/overrides/Head.astro, which no longer exists on the remove-starlight-ci branch. src/nimbus/scripts/footnotes.client.ts already provides the same footnote tooltip behavior for Nimbus, and src/nimbus/layouts/BaseLayout.astro loads it. Fix: Delete src/scripts/footnotes.ts; keeping it adds a stray dependency on Nimbus internals and duplication with the Nimbus footnotes client script.

Conventions

Warnings (1)
File Issue
PR Scope accuracy — The PR removes hundreds of legacy source files across src/components, src/pages, src/plugins, src/schemas, src/styles, src/util, bin/, and others, but the description only discusses CI workflows, astro.config.ts, Wrangler configs, worker redirects, package.json, and tsconfig excludes. Fix: Add a section summarizing the wholesale deletion of legacy Starlight source directories (components, pages, plugins, schemas, styles, utilities, etc.).

Style Guide Review

No style-guide issues found.

Commands

Only codeowners can run commands. Post a comment with the command to trigger it.

Command Description
/review Runs a review now. Incremental if a prior review exists, full if not.
/full-review Re-reviews the entire PR diff from scratch, ignoring incremental history. Useful after a rebase, when you want a fresh review, or if the bot gets out of sync and reports issues that no longer exist.
/ignore-review-limit Permanently lifts the 2-review automatic limit for this PR. Future pushes will trigger reviews as normal.
/disable-auto-review Stops automatic reviews from triggering on future pushes to this PR. Codeowners can still run /review or /full-review manually.
/rebase Rebases the PR branch against production. On conflict, attempts to resolve automatically using AI. Stops with an explanation if confidence is not high enough.

@mvvmm mvvmm changed the title chore: complete Starlight → Nimbus migration cleanup chore: Starlight → Nimbus migration cleanup Jul 21, 2026
@mvvmm
mvvmm force-pushed the remove-starlight-ci branch from 585addf to 8d7c033 Compare July 21, 2026 15:43
@mvvmm

mvvmm commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

CR-eff38308ceed (formatBytes negative input): Skipping. scripts/optimize-svgs.ts is a dev-only utility; the consequence of a negative originalSize - optimizedSize is a cosmetic log line with NaN. Not worth the noise in this PR.

@mvvmm

mvvmm commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

CR-f5d555a92aac and CR-083f45bcec5f: Both were fixed in earlier commits on this branch — dist-nimbus/ and .astro-cache-nimbus/ were removed from .gitignore, and src/scripts/footnotes.ts was deleted. These findings are stale.

@mvvmm
mvvmm merged commit 31148ed into production Jul 21, 2026
14 checks passed
@mvvmm
mvvmm deleted the remove-starlight-ci branch July 21, 2026 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants