local: implement DirSetModTime

This commit is contained in:
nielash 2024-01-13 08:19:37 -05:00 committed by Nick Craig-Wood
parent 61d76ae47d
commit 67e3725205

View File

@ -643,6 +643,16 @@ func (f *Fs) Mkdir(ctx context.Context, dir string) error {
return nil return nil
} }
// DirSetModTime sets the directory modtime for dir
func (f *Fs) DirSetModTime(ctx context.Context, dir string, modTime time.Time) error {
o := Object{
fs: f,
remote: dir,
path: f.localPath(dir),
}
return o.SetModTime(ctx, modTime)
}
// Rmdir removes the directory // Rmdir removes the directory
// //
// If it isn't empty it will return an error // If it isn't empty it will return an error
@ -1472,6 +1482,7 @@ var (
_ fs.DirMover = &Fs{} _ fs.DirMover = &Fs{}
_ fs.Commander = &Fs{} _ fs.Commander = &Fs{}
_ fs.OpenWriterAter = &Fs{} _ fs.OpenWriterAter = &Fs{}
_ fs.DirSetModTimer = &Fs{}
_ fs.Object = &Object{} _ fs.Object = &Object{}
_ fs.Metadataer = &Object{} _ fs.Metadataer = &Object{}
) )