xcopy.exe is definitely your friend here.
(xcopy.exe绝对是你的朋友。)
It's built into Windows, so its cost is nothing. (它内置于Windows中,因此它的成本一无所获。)
Just xcopy /sc:\source d:\target
(只需xcopy /sc:\source d:\target
)
You'd probably want to tweak a few things;
(你可能想要调整一些东西;)
some of the options we also add include these: (我们还添加了一些选项包括:)
-
/s/e
- recursive copy, including copying empty directories. (/s/e
- 递归复制,包括复制空目录。)
-
/v
- add this to verify the copy against the original. (/v
- 添加此项以验证原始副本。)
slower, but for the paranoid. (较慢,但对于偏执狂。)
-
/h
- copy system and hidden files. (/h
- 复制系统和隐藏文件。)
-
/k
- copy read-only attributes along with files. (/k
- 将只读属性与文件一起复制。)
otherwise, all files become read-write. (否则,所有文件都变为读写。)
-
/x
- if you care about permissions, you might want /o
or /x
. (/x
- 如果您关心权限,则可能需要/o
或/x
。)
-
/y
- don't prompt before overwriting existing files. (/y
- 在覆盖现有文件之前不要提示。)
-
/z
- if you think the copy might fail and you want to restart it, use this. (/z
- 如果您认为副本可能会失败并且您想要重新启动它,请使用此方法。)
It places a marker on each file as it copies, so you can rerun the xcopy command to pick up from where it left off. (它在复制时在每个文件上放置一个标记,因此您可以重新运行xcopy命令以从中断的位置进行拾取。)
If you think the xcopy might fail partway through (like when you are copying over a flaky network connection), or that you have to stop it and want to continue it later, you can use xcopy /s/zc:\source d:\target
.
(如果您认为xcopy可能在中途失败(例如,当您通过片状网络连接进行复制时),或者您必须停止它并希望以后继续它,则可以使用xcopy /s/zc:\source d:\target
。)
Hope this helps.
(希望这可以帮助。)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…