[WIN] [CMD] robocopy——windows file deep copy, retain file attributes

robocopy

Click to view the official Microsoft document robocopy | Microsoft Docs

File copy code without changing attributes:

# 需要注意的是,该命令必须在管理员权限下才可以运行吼
robocopy /copyall source destination

Demo

The purpose of executing twice is to imagecopy the attributes of the file

robocopy /copyall /e c:\Hexo\source\_posts\2021\images c:\hexo\source\_posts\2021\images1

# 紧接着再执行一次

robocopy /copyall c:\Hexo\source\_posts\2021\images c:\hexo\source\_posts\2021\images1

copy result
copy result
copy result

Guess you like

Origin blog.csdn.net/Fuel_Ming/article/details/123806485