forked from TrueCloudLab/rclone
local: ignore directory based junction points on windows
These are a kind of symlink and rclone doesn't follow symlinks. Fixes #692
This commit is contained in:
parent
bfe6f299d0
commit
bb21cf6f0e
1 changed files with 3 additions and 1 deletions
|
@ -174,7 +174,9 @@ func (f *Fs) list(out fs.ListOpts, remote string, dirpath string, level int) (su
|
|||
newRemote := path.Join(remote, name)
|
||||
newPath := filepath.Join(dirpath, name)
|
||||
if fi.IsDir() {
|
||||
if out.IncludeDirectory(newRemote) {
|
||||
// Ignore directories which are symlinks. These are junction points under windows which
|
||||
// are kind of a souped up symlink. Unix doesn't have directories which are symlinks.
|
||||
if (fi.Mode()&os.ModeSymlink) == 0 && out.IncludeDirectory(newRemote) {
|
||||
dir := &fs.Dir{
|
||||
Name: f.cleanRemote(newRemote),
|
||||
When: fi.ModTime(),
|
||||
|
|
Loading…
Reference in a new issue