import type { Dirent } from "node:fs"; /** * Like `readdirOrEmpty`, but returns `Dirent` entries to know if an entry is a * directory or not without an extra `lstat` syscall. */ export declare function readdirWithFileTypesOrEmpty(dirFrom: string): Promise; /** * Determines if a dirent refers to a directory, falling back to `lstat` only * when the dirent type is unknown. */ export declare function isDirectoryDirentAware(absolutePath: string, dirent: Dirent): Promise; /** * Recursively walk the directory tree rooted at `dirFrom`, appending the * absolute paths of every file accepted by `matches` to `results`. Descent * into a subdirectory is gated by `directoryFilter`. When either callback is * omitted, every file or directory is accepted. */ export declare function collectAllFilesMatching(dirFrom: string, results: string[], matches?: (absolutePathToFile: string) => Promise | boolean, directoryFilter?: (absolutePathToDir: string) => Promise | boolean): Promise; /** * Recursively walk the directory tree rooted at `dirFrom`, appending the * absolute paths of every directory accepted by `matches` to `results`. When * a directory matches, its descendants are not explored; when it does not, * the walk continues into its subdirectories. When `matches` is omitted, * every directory is accepted and recursion stops at the top level. */ export declare function collectAllDirectoriesMatching(dirFrom: string, results: string[], matches?: (absolutePathToDir: string) => Promise | boolean): Promise; //# sourceMappingURL=fs.d.ts.map