소스 검색

Merge pull request #312 from eza-community/revert-225-main

Revert "Support for Windows Hidden Files"
Christina Sørensen 2 년 전
부모
커밋
86baedebe2
1개의 변경된 파일3개의 추가작업 그리고 16개의 파일을 삭제
  1. 3 16
      src/fs/dir.rs

+ 3 - 16
src/fs/dir.rs

@@ -129,24 +129,11 @@ impl<'dir, 'ig> Files<'dir, 'ig> {
                     }
                 }
 
-                let file = File::from_args(
-                    path.clone(),
-                    self.dir,
-                    filename,
-                    self.deref_links
-                ).map_err(|e| (path.clone(), e));
-
-                // Windows has its own concept of hidden files, with a flag
-                // stored in the file's attributes
-                #[cfg(windows)]
-                if !self.dotfiles && file.as_ref().is_ok_and(|f| f.attributes().hidden) {
-                    continue;
-                }
-
-                return Some(file);
+                return Some(File::from_args(path.clone(), self.dir, filename, self.deref_links)
+                                 .map_err(|e| (path.clone(), e)))
             }
 
-            return None;
+            return None
         }
     }
 }