walker: Append path separator to directories

Close #4255
This commit is contained in:
Junegunn Choi committed 2025-02-18 22:03:59 +09:00
1 parent f975b40236
commit 6fa8295ac5
2 files changed
+3 -2

No files matched your search

+1
View File
@@ -320,6 +320,7 @@ func (r *Reader) readFiles(roots []string, opts walkerOpts, ignores []string) bo
return filepath.SkipDir
}
}
path += sep
}
if ((opts.file && !isDir) || (opts.dir && isDir)) && r.pusher(stringBytes(path)) {
atomic.StoreInt32(&r.event, int32(EvtReadNew))