commit 76dcf01d7030c580a2b0421ee4cfd19689c52065
parent 8a454b8e63aa90ecd69e43264ec304ac735083db
Author: William Casarin <jb55@jb55.com>
Date: Thu, 26 Feb 2026 10:05:12 -0800
dave: check for .exe extension in PATH lookup on Windows
has_binary_on_path only checked for the bare binary name,
which doesn't match on Windows where executables have .exe.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat:
1 file changed, 5 insertions(+), 0 deletions(-)
diff --git a/crates/notedeck_dave/src/config.rs b/crates/notedeck_dave/src/config.rs
@@ -8,6 +8,11 @@ pub fn has_binary_on_path(binary: &str) -> bool {
env::var_os("PATH")
.map(|paths| env::split_paths(&paths).any(|dir| dir.join(binary).is_file()))
.unwrap_or(false)
+ || env::var_os("PATH")
+ .map(|paths| {
+ env::split_paths(&paths).any(|dir| dir.join(format!("{}.exe", binary)).is_file())
+ })
+ .unwrap_or(false)
}
/// Detect which agentic backends are available based on binaries in PATH.