DirSetModTime sets the directory modtime for dir
(ctx context.Context, dir string, modTime time.Time)
| 439 | |
| 440 | // DirSetModTime sets the directory modtime for dir |
| 441 | func (f *Fs) DirSetModTime(ctx context.Context, dir string, modTime time.Time) error { |
| 442 | upstreams, err := f.action(ctx, dir) |
| 443 | if err != nil { |
| 444 | return err |
| 445 | } |
| 446 | errs := Errors(make([]error, len(upstreams))) |
| 447 | multithread(len(upstreams), func(i int) { |
| 448 | u := upstreams[i] |
| 449 | // ignore DirSetModTime on upstreams which don't support it |
| 450 | if do := u.Features().DirSetModTime; do != nil { |
| 451 | err := do(ctx, dir, modTime) |
| 452 | if err != nil { |
| 453 | errs[i] = fmt.Errorf("%s: %w", upstreams[i].Name(), err) |
| 454 | } |
| 455 | } |
| 456 | }) |
| 457 | return errs.Err() |
| 458 | } |
| 459 | |
| 460 | // ChangeNotify calls the passed function with a path |
| 461 | // that has had changes. If the implementation |