-i: Builds index for the files in the current working directory and saves it inmtfs-index.txt.-r "<PATH>": Builds index for the directory passed as<PATH>.
-s "<SEARCH_TERM>": Performs a multi-threaded search for<SEARCH_TERM>in the indexed files. The results are displayed on the console.-f "<SEARCH_TERM>": Performs a single-threaded search for<SEARCH_TERM>in the indexed files. The results are displayed on the console.
-igf "<FILES>": Ignore specific files during indexing, where<FILES>is a comma-separated list of file names.-igd "<DIRECTORIES>": Ignore specific directories during indexing, where<DIRECTORIES>is a comma-separated list of directory names.-ige "<EXTENSIONS>": Ignore specific file extensions during indexing, where<EXTENSIONS>is a comma-separated list of file extensions.
NOTE:
- Multithreaded search is performed using the maximum available physical threads on the CPU.
- Searching is case-insensitive.
- Common folders such as
.gitandnode_modulesand files with extensions.classand.gzare ignored by default.
CLIManagerpackage for parsing out CLI args.- Search space optimization similar to
ripgrep. - Multi-threaded file content searching based on a work-stealing queue.
- Single-threaded file content search.
- Fuzzy searching algorithm using Levenshtein distance.
BoundedPriorityQueuemade thread-safe.BoundedPriorityQueueto store search results.Serializerclass to cache indexed file tree in a file.- Custom
ThreadPoolManager. ThreadSafeQueue.- Multi-threaded file indexing.
- Multi-threaded BFS file searching.
- Single-threaded DFS file searching.
- Single-threaded BFS file searching.
- Single-threaded file indexing.