Move the directory searching / globbing code out of slurpFiles and into the filelist module so it can be used elsewhere.