-
Notifications
You must be signed in to change notification settings - Fork 11
Filter out hidden and extensionless files from watching #3
Filter out hidden and extensionless files from watching #3
Conversation
Yeah, I think we probably want to put the logic here to Lines 72 to 102 in 31eec52
|
Where should the |
Couldn't we also run the check in fn is_excluded(&self, path: &RelativePath) -> bool {
///...
let full_path = path.to_path(&self.path);
/// use full_path for checking via metadata
} In the case where we have a file without extension |
@vipentti oh, right... Yeah, I think that'll work fine. I worry a tiny bit about making syscall there, from performance and purity point of view, but I guess we can always optimize later. |
31eec52
to
55f333d
Compare
What about |
@bjorn3 this is an intended limitation at the moment. A long term plan would be to allow the user to explicitly whitelist weird files for inclusion. |
Got it. |
I think match path.extension() {
Some("rs") => false,
Some(_) => true,
// Exclude extension-less and hidden files
None => is_extensionless_or_hidden_file(&self.path, path),
} |
bors r+ |
3: Filter out hidden and extensionless files from watching r=matklad a=vipentti Relates to discussion in rust-lang/rust-analyzer#869 I'm not sure if this is the appropriate place to do the filtering. Co-authored-by: Ville Penttinen <[email protected]>
Build succeeded
|
Relates to discussion in rust-lang/rust-analyzer#869
I'm not sure if this is the appropriate place to do the filtering.