【发布时间】:2010-04-08 06:05:51
【问题描述】:
我想通过 xcopy 一次复制多个文件。可能吗。我的意思是:
xcopy file1+file2+file3 目标文件夹
任何帮助表示赞赏:)
【问题讨论】:
标签: command-line xcopy
我想通过 xcopy 一次复制多个文件。可能吗。我的意思是:
xcopy file1+file2+file3 目标文件夹
任何帮助表示赞赏:)
【问题讨论】:
标签: command-line xcopy
我使用以下内容复制数百个文件并按文件扩展名过滤它们。下面我说给我所有文件扩展名为 .dll、.exe 或 .pdf 的文件
for %f in (dll,exe,pdf) do xcopy /s /i C:\source\*.%f C:\destination
【讨论】:
我认为单个 xcopy 不可能,但您可以使用 for 语句。
类似的东西:
for %f in (file1, file2, filen) do xcopy %f dest\
【讨论】:
for /? 以获取更多信息
for %f in (file1,file2,file3) do xcopy %f destinationfolder
【讨论】:
如果您的文件以特定模式开头,您可以使用通配符(例如以 file 开头的文本文件)
copy file*.txt e:\destination
【讨论】: