Skip to content
Myr

Fix search with hidden root path

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by sharkdp · committed by sharkdp · parent 9bf008b · Browse files · 1 file+3 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−1 removed

  • other:+3 added−1 removed

1 file+3 added−1 removed

modified:src/main.rs+3 added-1 removed
104 unmodified lines
105 let walker = WalkDir::new(root)106 .follow_links(config.follow_links)107 .max_depth(config.max_depth)108 .into_iter()109 .filter_entry(|e| config.search_hidden || !is_hidden(e))109 .filter_entry(|e| config.search_hidden110 || !is_hidden(e)111 || e.path() == root)112 .filter_map(|e| e.ok())113 .filter(|e| e.path() != root);114115 for entry in walker {
148 unmodified lines