From 6c852655dd2cb37023f256033efe671a4db02680 Mon Sep 17 00:00:00 2001 From: Fabian Boehm Date: Wed, 11 Dec 2024 16:56:14 +0100 Subject: [PATCH] Disable man page building in clippy This would otherwise break any clippy run if you didn't have sphinx installed. --- build.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build.rs b/build.rs index 1584b14a8..05298dff0 100644 --- a/build.rs +++ b/build.rs @@ -37,6 +37,7 @@ fn main() { std::env::set_var("FISH_BUILD_VERSION", version); #[cfg(feature = "installable")] + #[cfg(not(clippy))] { let cman = std::fs::canonicalize(env!("CARGO_MANIFEST_DIR")).unwrap(); let targetman = cman.as_path().join("target").join("man"); @@ -336,6 +337,8 @@ fn get_version(src_dir: &Path) -> String { } #[cfg(feature = "installable")] +// disable clippy because otherwise it would panic without sphinx +#[cfg(not(clippy))] fn build_man(build_dir: &Path) { use std::process::Command; let mandir = build_dir;