A flexible and fluent Node.js library for searching and filtering files and directories on the file system.
Filehound is a Node.js library that provides a fluent, chainable interface for searching and filtering files and directories on the file system. It simplifies complex file system queries by allowing developers to build expressive search criteria using methods like paths, extensions, names, and sizes. It solves the problem of verbose and repetitive file system traversal code in Node.js applications.
Node.js developers who need to perform complex file searches, such as those building build tools, CLI applications, or scripts that require file system scanning and filtering.
Developers choose Filehound for its clean, readable API that reduces boilerplate code, its support for both async and sync operations, and its powerful filtering capabilities that go beyond basic glob patterns.
Flexible and fluent interface for searching the file system
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Enables building complex search queries with readable, method-chaining syntax, as demonstrated in the README example where .paths(), .ext(), and .find() are chained for clear code.
Supports filtering by extension, name patterns (glob/regex), size, modification time, and custom criteria, allowing precise file searches without manual boilerplate code.
Provides both promise-based asynchronous methods and synchronous counterparts, giving developers flexibility in handling file I/O, as indicated in the key features.
Includes features like depth limits for recursion and boolean operators (negation, combination), simplifying complex directory traversals without custom logic.
Full API details are hosted on a separate site (nspragg.github.io/filehound/), which may be less accessible or up-to-date compared to comprehensive inline README documentation.
The fluent API abstraction layer could introduce slight performance penalties compared to using the Node.js fs module directly, especially in high-frequency or latency-sensitive operations.
As a standalone library, it doesn't seamlessly integrate with larger Node.js toolchains or frameworks, potentially requiring extra code for advanced workflows like build pipelines.