windows - Can xcopy transfer the files in a subdirectory, but not the directories themselves? -
essentially, want copy *.txt current directory subdirectories. if xcopy /s /e c:\source c:\dest
, copies not files, directory structure well. need files copied, c:\dest
contains nothing *.txt files. checked documentation both xcopy , robocopy, couldn't find parameters allowed functionality.
how using loop? it'll execute lots of copy commands, give try:
for /r c:\source %%f in (*.txt) xcopy /s "%%f" "c:\dest"
Comments
Post a Comment