Open-Source Wikis

/

fd

/

fd

sharkdp/fd

fd

fd is a command-line program for finding files and directories in your filesystem. It is written in Rust and packaged as the fd-find crate. The single binary it produces, also called fd, is positioned as a simple, fast, and user-friendly alternative to GNU find.

The tool does not aim to replicate every feature of find. Instead, it picks an opinionated default behaviour that fits most everyday searches: case-insensitive smart-case matching against file names, recursive walking from the current directory, hidden and .gitignore-respecting filtering, parallel traversal, colorized output, and built-in support for executing commands against each match.

What you can do with fd

  • Search for files by regular expression: fd PATTERN.
  • Use globs instead with -g/--glob, or treat the pattern as a literal with -F/--fixed-strings.
  • Filter by file type, extension, size, modification time, or owner.
  • Run a command for every match (-x/--exec) or a single command on the whole batch (-X/--exec-batch), with placeholder substitution for paths, basenames, parents, and stem.
  • Honour .gitignore, .ignore, .fdignore, and a global ignore file by default; turn that off with -I/--no-ignore or -u/--unrestricted.
  • Generate shell completions for bash, zsh, fish, and PowerShell via fd --gen-completions.

Project at a glance

Item Value
Repository https://github.com/sharkdp/fd
Crate fd-find
Latest version 10.4.2 (see Cargo.toml)
Edition / MSRV Rust edition 2024, minimum supported Rust version 1.90.0
License MIT or Apache-2.0 (dual-licensed)
Binary fd (entry point: src/main.rs)
Lines of Rust source ~4,780 across src/
Integration tests ~2,800 lines in tests/tests.rs

Where to go next

  • Architecture — the components inside the binary and how a search request flows through them.
  • Getting started — building from source, running the test suite, and installing the binary.
  • Glossary — fd-specific terms used throughout the wiki.
  • How to contribute — workflow, coding patterns, and the test harness.
  • Systems — deep dives into the walker, filters, command execution, and output.
  • Features — cross-cutting capabilities like smart case, ignore handling, and exec templates.

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

fd – fd wiki | Factory