Esempio n. 1
0
        private Result SynchronizeDirectory(string dest, string src)
        {
            Result rc = BaseFs.DeleteDirectoryRecursively(dest);

            if (rc.IsFailure() && rc != ResultFs.PathNotFound)
            {
                return(rc);
            }

            rc = BaseFs.CreateDirectory(dest);
            if (rc.IsFailure())
            {
                return(rc);
            }

            return(BaseFs.CopyDirectory(BaseFs, src, dest));
        }