Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to exclude .svn folders with robocopy

does anyone know how to exclude .svn folders with Robocopy? I want to copy all folders but I want to prevent to copy the subversion folders that svn creates.

Any ideas on this?

Thanks in advance.

like image 222
Teun Pronk Avatar asked Dec 01 '11 11:12

Teun Pronk


People also ask

How do I exclude a directory in Robocopy?

The most important switches in this command are the /XD which allows you to exclude folders, and /XF that you can use to exclude files. The other options are optional, but you should use these options that you should use in any standard copy process using Robocopy.

How do I skip files in Robocopy?

If you use the R and W switches with an argument of 0, then Robocopy should just skip errors and continue . . .

What is .SVN folder?

svn, also known as the working copy's administrative directory. The files in each administrative directory help Subversion recognize which files contain unpublished changes, and which files are out of date with respect to others' work.

What is Robocopy XD?

Robocopy allows you to filter items not just by file but by directory name too. Using robocopy /xd , you can exclude certain directories matching a specific name. When copying multiple folders, use the /XD switch to exclude folders from the run.


1 Answers

The /xd ".svn" folder exclusion should help in your case.

like image 117
Michael Avatar answered Sep 21 '22 12:09

Michael