This helper function recursively yields relative pathnames inside a literal directory.
| 349 | // This helper function recursively yields relative pathnames inside a literal |
| 350 | // directory. |
| 351 | Vector<String> glob2(const String &dirname, [[maybe_unused]] const String &pattern, |
| 352 | bool dironly, bool include_hidden) { |
| 353 | // std::cout << "In glob2\n"; |
| 354 | Vector<String> result = rlistdir(dirname, dironly, include_hidden); |
| 355 | //assert(is_recursive(pattern)); |
| 356 | if (dironly) { |
| 357 | result.push_back(dirname); |
| 358 | } |
| 359 | return result; |
| 360 | } |
| 361 | |
| 362 | // These 2 helper functions non-recursively glob inside a literal directory. |
| 363 | // They return a list of basenames. _glob1 accepts a pattern while _glob0 |