in util/fs.go [28:43]
func MatchPaths(dir string, re *regexp.Regexp) ([]string, error) {
dirEntries, err := ioutil.ReadDir(dir)
if err != nil {
return nil, err
}
var matches []string
for _, entry := range dirEntries {
if re.MatchString(entry.Name()) {
matches = append(matches, entry.Name())
}
}
return matches, nil
}