1
0
mirror of https://github.com/go-task/task.git synced 2025-11-23 22:24:45 +02:00

feat: support negative globs (#1324)

Co-authored-by: Andrey Nering <andrey@nering.com.br>
This commit is contained in:
Pete Davison
2023-11-29 19:38:12 -06:00
committed by GitHub
parent a7958c0e3b
commit ec35d43677
14 changed files with 173 additions and 50 deletions

View File

@@ -142,7 +142,12 @@ func (e *Executor) registerWatchedFiles(w *watcher.Watcher, calls ...taskfile.Ca
}
}
for _, s := range task.Sources {
globs, err := fingerprint.Globs(task.Dir, task.Sources)
if err != nil {
return err
}
for _, s := range globs {
files, err := fingerprint.Glob(task.Dir, s)
if err != nil {
return fmt.Errorf("task: %s: %w", s, err)