Change depth in existing SVN working copy without redownloading

sparse-checkoutsvnsvn-update

I have a working copy of an entire SVN repository, but I want to change it into a sparse working copy because of disk space issues.

One way to do this would be:

svn up --set-depth immediates projects
svn up --set-depth infinity projects/project1
svn up --set-depth infinity projects/project2

However, that would first delete project1 and project2, then redownload them. This is really inconvenient, because they're very large and the server's upload speed is very low. I tried this (with another, smaller, part of the repo, as an experiment):

svn up --set-depth infinity projects/project1
svn up --set-depth infinity projects/project2
svn up --set-depth immediates projects

But then the last command just undoes the first 2.

How can I set the depth of a working copy without it immediately updating/changing it, so I can have the chance to correctly configure subdirectories first?

Or is there another way to accomplish what I want, e.g. by copying project1 and project2 to a safe location first?

Best Answer

Woo hoo, I had this problem, and TortoiseSVN has supported solutions for both add and delete an item from the sparse checkout. http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-dug-checkout.html

1.To add: In windows explorer, Right click on the checked out folder, then use TortoiseSVN ? Repo-Browser to bring up the repository browser. Find the sub-folder you would like to add to your working copy, then use Context Menu ? Update item to revision....

2.To delete; From your root, right-click / Repo-Browser / Update item to revision; then select 'Exclude'.

Related Topic