在Windows命令行上复制文件并进行进度

时间:2020-03-05 18:52:09  来源:igfitidea点击:

有谁知道Windows命令行(默认在XP Pro或者更高版本上可用)可以在显示进度时复制文件。我不在乎进度指示器是在终端还是GUI窗口中。

这旨在在批处理文件脚本编写期间使用

解决方案

回答

我们可以很容易地编写一个程序来执行此操作,我已经编写了几个程序,这些字节在复制文件时显示复制的字节。如果我们有兴趣,请发表评论,我会发布一个链接。

回答

robocopy:

Robocopy, or "Robust File Copy", is a command-line directory and/or file replication command. Robocopy functionally replaces Xcopy, with more options. It has been available as part of the Windows Resource Kit starting with Windows NT 4.0, and was first introduced as a standard feature in Windows Vista and Windows Server 2008. The command is robocopy...

回答

此technet链接具有一些用于复制大文件的良好信息。我使用了本文中提到的Exchange Server实用程序,该实用程序显示了进度并在内部使用了非缓冲复制功能来加快传输速度。

在另一种情况下,我使用了robocopy。 Robocopy GUI使我们更容易正确设置命令行选项。