ROBOCOPY or XCOPY exclude

Joined
May 23, 2008
Messages
1
Reaction score
0
Hi,

How can I use the exclude option to exclude all files under a certain folder name. The problem is that I have a very deep directory structure with every folder containing the same folder name. For example:

"c:\docs" contains the following:

\doc1\uploads\
\doc2\uploads\

and so on...

how can I write a simple script that I can copy c:\docs to d:\docs but exclude all files under the "uploads". What do I need to put after "robocopy c:\docs d:\docs /s /XF" or "xcopy c:\docs d:\docs /s /EXCLUDE" without using an absolute path, somehow looking for the word "uploads" and excluding all files in these folders?

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top