|
@@ -246,8 +246,8 @@ func (w *walker) walkAndHashFiles(ctx context.Context, fchan, dchan chan protoco
|
|
|
if w.Matcher.Match(path).IsIgnored() {
|
|
if w.Matcher.Match(path).IsIgnored() {
|
|
|
l.Debugln("ignored (patterns):", path)
|
|
l.Debugln("ignored (patterns):", path)
|
|
|
// Only descend if matcher says so and the current file is not a symlink.
|
|
// Only descend if matcher says so and the current file is not a symlink.
|
|
|
- if w.Matcher.SkipIgnoredDirs() || (info.IsSymlink() && info.IsDir()) {
|
|
|
|
|
- return fs.SkipDir
|
|
|
|
|
|
|
+ if w.Matcher.SkipIgnoredDirs() || info.IsSymlink() {
|
|
|
|
|
+ return skip
|
|
|
}
|
|
}
|
|
|
// If the parent wasn't ignored already, set this path as the "highest" ignored parent
|
|
// If the parent wasn't ignored already, set this path as the "highest" ignored parent
|
|
|
if info.IsDir() && (ignoredParent == "" || !strings.HasPrefix(path, ignoredParent+string(fs.PathSeparator))) {
|
|
if info.IsDir() && (ignoredParent == "" || !strings.HasPrefix(path, ignoredParent+string(fs.PathSeparator))) {
|