blob: 833ce358c6166b271f37186a055875caa0c645d8 [file] [log] [blame]
Tony Mackebaad212013-04-07 20:44:28 -04001import os, fnmatch
2
3def recursive_glob(treeroot, pattern):
4 results = []
5 for base, dirs, files in os.walk(treeroot):
6 goodfiles = fnmatch.filter(files, pattern)
7 results.extend(os.path.join(base, f) for f in goodfiles)
8 return results