From 640a0346cedddaff1ba55a09259bfc5cf1e92079 Mon Sep 17 00:00:00 2001 From: Wilfred Hughes Date: Mon, 1 Dec 2025 14:03:25 +0000 Subject: [PATCH] Remove mdbook-toc usage Now that there's a table of contents rendered in the left sidebar, there doesn't seem to be much value in rendering a table of contents on the page too. The sidebar TOC was added in mdbook 0.5: https://github.com/rust-lang/mdBook/blob/master/CHANGELOG.md#05-migration-guide --- src/tools/rust-analyzer/docs/book/README.md | 1 - src/tools/rust-analyzer/docs/book/book.toml | 5 ----- src/tools/rust-analyzer/docs/book/src/contributing/README.md | 2 -- .../rust-analyzer/docs/book/src/contributing/architecture.md | 2 -- src/tools/rust-analyzer/docs/book/src/contributing/guide.md | 2 -- .../docs/book/src/contributing/lsp-extensions.md | 2 -- src/tools/rust-analyzer/docs/book/src/other_editors.md | 2 -- 7 files changed, 16 deletions(-) diff --git a/src/tools/rust-analyzer/docs/book/README.md b/src/tools/rust-analyzer/docs/book/README.md index 11f7e8f98ca5..0a3161f3af38 100644 --- a/src/tools/rust-analyzer/docs/book/README.md +++ b/src/tools/rust-analyzer/docs/book/README.md @@ -8,7 +8,6 @@ To run the documentation site locally: ```shell cargo install mdbook -cargo install mdbook-toc cargo xtask codegen cd docs/book mdbook serve diff --git a/src/tools/rust-analyzer/docs/book/book.toml b/src/tools/rust-analyzer/docs/book/book.toml index c77eabda1489..0978851d5009 100644 --- a/src/tools/rust-analyzer/docs/book/book.toml +++ b/src/tools/rust-analyzer/docs/book/book.toml @@ -33,8 +33,3 @@ use-boolean-and = true [output.html.fold] enable = true level = 3 - -[preprocessor.toc] -command = "mdbook-toc" -renderer = ["html"] -max-level = 3 diff --git a/src/tools/rust-analyzer/docs/book/src/contributing/README.md b/src/tools/rust-analyzer/docs/book/src/contributing/README.md index ad2816b18ac1..c95a1dba6249 100644 --- a/src/tools/rust-analyzer/docs/book/src/contributing/README.md +++ b/src/tools/rust-analyzer/docs/book/src/contributing/README.md @@ -26,8 +26,6 @@ Discussion happens in this Zulip stream: - - # Issue Labels * [good-first-issue](https://github.com/rust-lang/rust-analyzer/issues?q=is%3Aissue%20state%3Aopen%20label%3A%22good%20first%20issue%22) diff --git a/src/tools/rust-analyzer/docs/book/src/contributing/architecture.md b/src/tools/rust-analyzer/docs/book/src/contributing/architecture.md index f2b6c053b0b8..67653ebd7437 100644 --- a/src/tools/rust-analyzer/docs/book/src/contributing/architecture.md +++ b/src/tools/rust-analyzer/docs/book/src/contributing/architecture.md @@ -20,8 +20,6 @@ For older, by now mostly outdated stuff, see the [guide](./guide.md) and [anothe ![](https://user-images.githubusercontent.com/4789492/107129398-0ab70f00-687a-11eb-9bfc-d4eb023aec06.png) - - On the highest level, rust-analyzer is a thing which accepts input source code from the client and produces a structured semantic model of the code. More specifically, input data consists of a set of test files (`(PathBuf, String)` pairs) and information about project structure, captured in the so called `CrateGraph`. diff --git a/src/tools/rust-analyzer/docs/book/src/contributing/guide.md b/src/tools/rust-analyzer/docs/book/src/contributing/guide.md index 774eb5b2a53f..9e944bfe0fc4 100644 --- a/src/tools/rust-analyzer/docs/book/src/contributing/guide.md +++ b/src/tools/rust-analyzer/docs/book/src/contributing/guide.md @@ -12,8 +12,6 @@ however, it's based on an older 2019-01-20 release (git tag [guide-2019-01]): [guide-2019-01]: https://github.com/rust-lang/rust-analyzer/tree/guide-2019-01 [2024-01-01]: https://github.com/rust-lang/rust-analyzer/tree/2024-01-01 - - ## The big picture On the highest possible level, rust-analyzer is a stateful component. A client may diff --git a/src/tools/rust-analyzer/docs/book/src/contributing/lsp-extensions.md b/src/tools/rust-analyzer/docs/book/src/contributing/lsp-extensions.md index 0e91e1261221..5922f0b551d6 100644 --- a/src/tools/rust-analyzer/docs/book/src/contributing/lsp-extensions.md +++ b/src/tools/rust-analyzer/docs/book/src/contributing/lsp-extensions.md @@ -19,8 +19,6 @@ Requests, which are likely to always remain specific to `rust-analyzer` are unde If you want to be notified about the changes to this document, subscribe to [#4604](https://github.com/rust-lang/rust-analyzer/issues/4604). - - ## Configuration in `initializationOptions` **Upstream Issue:** diff --git a/src/tools/rust-analyzer/docs/book/src/other_editors.md b/src/tools/rust-analyzer/docs/book/src/other_editors.md index 896df52af5f9..f7116fc19a6c 100644 --- a/src/tools/rust-analyzer/docs/book/src/other_editors.md +++ b/src/tools/rust-analyzer/docs/book/src/other_editors.md @@ -6,8 +6,6 @@ Protocol](https://microsoft.github.io/language-server-protocol/). This page assumes that you have already [installed the rust-analyzer binary](./rust_analyzer_binary.html). - - ## Emacs To use `rust-analyzer`, you need to install and enable one of the two