fix: handle Windows paths in pre-commit tests (#2974)

Co-authored-by: houseme <housemecn@gmail.com>
This commit is contained in:
Henry Guo
2026-05-15 22:04:51 +08:00
committed by GitHub
parent 738fb86611
commit bca8b08c2b
15 changed files with 134 additions and 46 deletions
+9
View File
@@ -219,6 +219,15 @@ pub fn detect_storage_media(storage_detection_enabled: bool, storage_media_overr
}
}
#[cfg(not(any(target_os = "linux", target_os = "macos")))]
{
if let Ok(media) = detect_platform_storage_media()
&& media != StorageMedia::Unknown
{
return media;
}
}
StorageMedia::Unknown
}