Can I copy multiple named files on the Windows command line using a single “copy” command?

前端 未结 3 2108
名媛妹妹
名媛妹妹 2021-01-31 15:37

I\'d like to copy several known files to another directory as a part of a post-build event, but don\'t want to have lines and lines of \"copy [file] [destination] [switches]\" i

3条回答
  •  南方客
    南方客 (楼主)
    2021-01-31 16:00

    XP and Vista replaced xcopy with robocopy, and it will do exactly what you want. The syntax for what you want feels backwards at first, but it does the job:

    robocopy source\folder a\dest\folder file1.exe file2.bat file3.dll file4.txt
    

提交回复
热议问题