Staged docs releases (#50136)

Closes #ISSUE

Before you mark this PR as ready for review, make sure that you have:
- [x] Added a solid test coverage and/or screenshots from doing manual
testing
- [x] Done a self-review taking into account security and performance
aspects
- [x] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
This commit is contained in:
Ben Kunkle authored and GitHub committed 2026-04-30 11:10:14 +00:00
1 parent c499a95218
commit 62f7eaba0e
16 files changed
+639 -199

No files matched your search

+16 -1
View File
@@ -1,7 +1,22 @@
export default {
async fetch(request, _env, _ctx) {
const url = new URL(request.url);
url.hostname = "docs-anw.pages.dev";
if (url.pathname === "/docs/nightly") {
url.hostname = "docs-nightly.pages.dev";
url.pathname = "/docs/";
} else if (url.pathname.startsWith("/docs/nightly/")) {
url.hostname = "docs-nightly.pages.dev";
url.pathname = url.pathname.replace("/docs/nightly/", "/docs/");
} else if (url.pathname === "/docs/preview") {
url.hostname = "docs-preview-5xd.pages.dev";
url.pathname = "/docs/";
} else if (url.pathname.startsWith("/docs/preview/")) {
url.hostname = "docs-preview-5xd.pages.dev";
url.pathname = url.pathname.replace("/docs/preview/", "/docs/");
} else {
url.hostname = "docs-anw.pages.dev";
}
let res = await fetch(url, request);