fd is designed to find entries in your filesystem. The most basic search you
can perform is to run fd with a single argument: the search pattern. For
example, assume that you want to find an old script of yours (the name included
netflix):
> fd netfl
Software/python/imdb-ratings/netflix-details.pysh
regular expressions
> cd /etc
> fd '^x.*rc$'
X11/xinit/xinitrc
X11/xinit/xserverrc
specifying the root directory
> fd passwd /etc
/etc/default/passwd
/etc/pam.d/passwd
/etc/passwd
list all files, recursively
> cd fd/tests
> fd
testenv
testenv/mod.rs
tests.rs
recursively find all zip archives and unpack them
fd -e zip -x unzip
find all test_*.py files and open them in your favorite editor
fd -g 'test_*.py' -X vim
Note that we use capital -X here to open a single vim instance by passing all of them as arguments to a single command.
searching for a particular file extension
> cd fd
> fd -e md
CONTRIBUTING.md
README.md