This is a basic file search tool I wrote as an exercise. It supports a small subset of features and has a small, pretty neat source.
If no pattern is passed, it lists all files in the directory.
See pattern.rs for all the rules.
-
Free arguments: Pattern(s) for matching files. They can be:
/indicates the subdirectories to search:/*tarwill match all files having a parent directory containingtarin its name./targetwill only match files withtargetas the parent directory.
.to indicate the file extension:*.exematches all files ending in.exe
*matches everything.
You can also pass multiple of these and only list files which match them all.
-
--helpfor help -
--folders/-ffor listing folders. -
--root/-rfor specifying the directory to search. -
--depth/-dfor specifying the maximum depth to search.
This project is licensed under the MIT License.