diff --git a/commands/core/filegen.go b/commands/core/filegen.go index 89f1efb..e232eef 100644 --- a/commands/core/filegen.go +++ b/commands/core/filegen.go @@ -87,7 +87,16 @@ func FileGenerator(filters ...string) GeneratorFunc { continue } - if filePrefix != "" && !HasPrefix(name, filePrefix) { + match := false + if filePrefix == "" { + match = true + } else if dirOnly { + match = strings.Contains(strings.ToLower(name), strings.ToLower(filePrefix)) + } else { + match = HasPrefix(name, filePrefix) + } + + if !match { continue }