Get File Paths Without Directoires Using Walkdir In Rust
Code
//! ```cargo
//! [dependencies]
//! walkdir = "2"
//! ```
use PathBuf;
use WalkDir;
Results
[_active_nvim_run:13] file_list = [
"glob_test/echo.txt",
"glob_test/BRAVO.txt",
"glob_test/fOxtrOt.txt",
"glob_test/hotel.txt",
"glob_test/charlie.txt",
"glob_test/golf.txt",
"glob_test/delta.txt",
"glob_test/alfa.txt",
]
Notes
The example on the walkdir page uses `filter_entry()`` but that doesn't descend into a directory if it doesn't match. So, it doesn't find all matching files.
This gets all files based off extension without that filter blocking them.
This also converts the `WalkDir`` `DirEntry``s to `PathBuf``s