![]() Now, a little shell work to move things around. Svn checkout file:///svnroot/project1 /tmp/project1 It was possible to edit path information in the project dump files before loading them, but it seemed easier to check out a working copy of each, move things around, and then commit the changes. Subversion doesn't allow wildcard gobling, so it's impossible to do something like: Svnadmin load /svnroot/project2 < /tmp/project2.dump Cleanup new repository layout, move files from trunk/projectN to trunk/Įach repository layout now looks something like: Svnadmin load /svnroot/project1 < /tmp/project1.dump Svnadmin create /svnroot/project2 Load the filtered dump files into the new repositories The -drop-empty-revs and -renumber-revs options remove commit log messages for other folders and renumber the remaining revision numbers. There's also an exclude option that might come in handy if you're trying to remove one folder from a group of many. The key here is the include option which targets the project folder(s). Svnadmin dump /svnroot/originalproject > /tmp/original.dump Separate folders to separate files with svndumpfilterĬat /tmp/original.dump | svndumpfilter -drop-empty-revs -renumber-revs include trunk/project1 > /tmp/project1.dumpĬat /tmp/original.dump | svndumpfilter -drop-empty-revs -renumber-revs include trunk/project2 > /tmp/project2.dump I'll use tmp as working directory to dump and filter files. ![]() Delete the original branches, tags, and trunk repositories from svnroot.Cleanup the new repository layout, move files from trunk/projectN to trunk/.Load the filtered dump files into the new repositories.Separate folders in the dump to separate files with svndumpfilter.The basic steps to separate these repositories are: You'll need to put a bit more thought into how to deal with existing tags and branches. My repository's history isn't complex-it doesn't contain tags or branches yet. My goal is to create two new projects from folders stored in the trunk of a single repository. Fortunately, the svnadmin and svndumpfilter utilities make it relatively simple to separate repositories into individual projects. I initially decided to keep everything in one repository, but later decided to separate them out. I flip-flopped for a while on whether to keep projects in a single or separate repositories. I decided to install Subversion to manage my freelance projects last year and am getting up to speed on repository administration. I've been using Subversion since the Gallery Project switched to it from CVS a few years back.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |