I want to find a file foo.bar
on a disk (in order to read that file). If I am using Windows, I can use:
list.files(path = "C:/", pattern = "^foo\\.bar$", recursive = TRUE, full.names = TRUE)
but this is quite slow (11 seconds on my machine) -- in contrast, Search Everything returns the result in less than 2 seconds. Is there a faster pure R way? If there are multiple matches, any of the matches will do. Cross-platform solutions are preferred.