Closed cyberpunkbln closed 5 years ago
Sorry but i don't understand your question. Please provide a complete but minimal example of the code you're using. It should be a compilable and runnable program. Please then provide your input, along with the actual output and the expected output.
i have solved my problem, not the walkdir way with filter_entry but it does what it does;).
for entry in WalkDir::new("c:\").into_iter().filter_map(|e| e.ok())
{
let testlnk = entry.file_name().to_str().map(|s| s.ends_with(".exe")).unwrap_or(false);
if (testlnk)
{
println!("{}", entry.path().display());
}
}
A little bit hacky:).
I want only reveive a list with files that have an special ending like exe. Andir *.exe /s in rust :).
I'm glad you solved it. In the future, when filing bug reports or asking questions, please make sure to provide a complete compilable/runnable example, along with input, actual output and expected output.
Hello,
i will use your crate to filter all files with an extensions in an directory recursive. This are first steps with your crate:):
I think for me that the filter_entry only shows all entries that will be come true in the fn show? When i say !show(e) then he shows correctly all files that are not exe, but when in the code above he shows nothing?
thx