From 51618829899105afd2d2bc9b7666d3cb6e4533e4 Mon Sep 17 00:00:00 2001 From: bahdotsh Date: Wed, 27 Aug 2025 15:39:52 +0530 Subject: [PATCH] fix(utils): remove unused imports to fix Windows clippy warnings - Remove unused io::self import from common scope - Remove unused std::fs::OpenOptions and std::io::Write from windows_impl - Add std::io import to unix_impl to fix io::Error references - Ensure clippy passes with -D warnings on all platforms --- crates/utils/src/lib.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/crates/utils/src/lib.rs b/crates/utils/src/lib.rs index f4b4158..a71e84a 100644 --- a/crates/utils/src/lib.rs +++ b/crates/utils/src/lib.rs @@ -43,7 +43,7 @@ pub fn is_workflow_file(path: &Path) -> bool { /// differences in file descriptor handling. The functions will execute without /// error but stderr may not be fully suppressed. pub mod fd { - use std::io::{self, Result}; + use std::io::Result; /// Represents a redirected stderr that can be restored pub struct RedirectedStderr { @@ -61,6 +61,7 @@ pub mod fd { use nix::fcntl::{open, OFlag}; use nix::sys::stat::Mode; use nix::unistd::{close, dup, dup2}; + use std::io; use std::os::unix::io::RawFd; use std::path::Path; @@ -119,8 +120,6 @@ pub mod fd { #[cfg(windows)] mod windows_impl { use super::*; - use std::fs::OpenOptions; - use std::io::Write; impl RedirectedStderr { /// Creates a new RedirectedStderr that redirects stderr to NUL on Windows