| 67 | } |
| 68 | |
| 69 | void grepDirectory(SearchParameters const& search, String directory) { |
| 70 | for (pair<String, bool> entry : File::dirList(directory)) { |
| 71 | if (entry.second) |
| 72 | grepDirectory(search, File::relativeTo(directory, entry.first)); |
| 73 | else if (entry.first.endsWith(MapFilenameSuffix)) |
| 74 | grepMap(search, File::relativeTo(directory, entry.first)); |
| 75 | } |
| 76 | } |
| 77 | |
| 78 | void grepPath(SearchParameters const& search, String path) { |
| 79 | if (File::isFile(path)) { |