Remove legacy Sphinx docs/ and finish the Mintlify cutover (#28964)

This commit is contained in:
zijiexia
2026-07-13 15:06:08 -07:00
committed by GitHub
parent e2728ac504
commit 50ed4c011f
235 changed files with 141 additions and 48841 deletions
-62
View File
@@ -1,62 +0,0 @@
#!/usr/bin/env python3
"""Reject staged changes under the legacy docs/ tree."""
from __future__ import annotations
import subprocess
import sys
ERROR_MESSAGE = """\
Changes under the legacy docs/ directory are not allowed.
The documentation has been migrated. Please make documentation updates in the
corresponding location under docs_new/ instead.
"""
LEGACY_DOCS_ALLOWLIST = {
"docs/_static/css/custom_log.css",
"docs/_static/js/deprecation_banner.js",
"docs/conf.py",
# Has relative links into the source tree that the offline lychee check
# validates, so it must be updated when the linked source files move.
"docs/developer_guide/development_jit_kernel_guide.md",
}
def staged_paths() -> list[str]:
result = subprocess.run(
[
"git",
"diff",
"--cached",
"--name-only",
"--diff-filter=ACMRDTUXB",
],
check=True,
capture_output=True,
text=True,
)
return [line.strip() for line in result.stdout.splitlines() if line.strip()]
def main() -> int:
paths = sys.argv[1:] or staged_paths()
docs_paths = sorted(
path
for path in paths
if (path == "docs" or path.startswith("docs/"))
and path not in LEGACY_DOCS_ALLOWLIST
)
if not docs_paths:
return 0
print(ERROR_MESSAGE, file=sys.stderr)
print("Detected legacy docs/ changes:", file=sys.stderr)
for path in docs_paths:
print(f" - {path}", file=sys.stderr)
return 1
if __name__ == "__main__":
raise SystemExit(main())
+4 -4
View File
@@ -16,9 +16,9 @@ python scripts/release/bump_sglang_version.py 0.5.3rc0
- `Makefile`
- `benchmark/deepseek_v3/README.md`
- `docker/rocm.Dockerfile`
- `docs/get_started/install.md`
- `docs/platforms/amd_gpu.md`
- `docs/platforms/ascend_npu.md`
- `docs_new/docs/get-started/install.mdx`
- `docs_new/docs/hardware-platforms/amd_gpu.mdx`
- `docs_new/docs/hardware-platforms/ascend-npus/ascend_npu.mdx`
- `python/pyproject.toml`
- `python/pyproject_other.toml`
- `python/pyproject_npu.toml`
@@ -69,7 +69,7 @@ python scripts/release/bump_kernel_version.py 0.4.0
```bash
grep -r "0.5.4rc0" python/sglang/version.py
grep -r "0.5.4rc0" python/pyproject.toml
grep -r "0.5.4rc0" docs/get_started/install.md
grep -r "0.5.4rc0" docs_new/docs/get-started/install.mdx
```
4. **Reset changes (if testing):**