From c4b40178135190e6f4b11addbf81aea522b9d6a8 Mon Sep 17 00:00:00 2001 From: Weihang Lo Date: Wed, 26 Aug 2026 21:00:19 -0400 Subject: [PATCH] rustdoc: fix lint `cargo::non_kebab_case_bins` ``` warning: binary `rustdoc_tool_binary` should have a kebab-case name | 1 | /checkout/obj/build/x86_64-unknown-linux-gnu/bootstrap-tools/.../rustdoc_tool_binary | ^^^^^^^^^^^^^^^^^^^ | = note: `cargo::non_kebab_case_bins` is set to `warn` by default help: to change the binary name to `rustdoc-tool-binary`, convert `bin.name` --> src/tools/rustdoc/Cargo.toml:10:8 | 10 - name = "rustdoc_tool_binary" 10 + name = "rustdoc-tool-binary" | warning: `rustdoc-tool` (manifest) generated 1 warning ``` See --- src/bootstrap/src/core/build_steps/tool.rs | 2 +- src/tools/rustdoc/Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bootstrap/src/core/build_steps/tool.rs b/src/bootstrap/src/core/build_steps/tool.rs index 922784fb7e13a..c4fae69645e85 100644 --- a/src/bootstrap/src/core/build_steps/tool.rs +++ b/src/bootstrap/src/core/build_steps/tool.rs @@ -797,7 +797,7 @@ impl CommandLineStep for Rustdoc { // Cargo adds a number of paths to the dylib search path on windows, which results in // the wrong rustdoc being executed. To avoid the conflicting rustdocs, we name the "tool" // rustdoc a different name. - tool: "rustdoc_tool_binary", + tool: "rustdoc-tool-binary", mode: Mode::ToolRustcPrivate, path: "src/tools/rustdoc", source_type: SourceType::InTree, diff --git a/src/tools/rustdoc/Cargo.toml b/src/tools/rustdoc/Cargo.toml index 681256665d688..c849625bda487 100644 --- a/src/tools/rustdoc/Cargo.toml +++ b/src/tools/rustdoc/Cargo.toml @@ -7,7 +7,7 @@ edition = "2024" # the wrong rustdoc being executed. To avoid the conflicting rustdocs, we name the "tool" # rustdoc a different name. [[bin]] -name = "rustdoc_tool_binary" +name = "rustdoc-tool-binary" path = "main.rs" [dependencies]