With different projects, different content and also several ways of organizing the directories of the project and of course different ways of doing the same thing from the CVS and Subversion world.
Now it is time to look at the current subversion repository and see what we can do on a first step to make it more organized.
But first, we need to look on how to make a backup of the current single repository and make sure we can go back if something goes wrong.
An approach i will use, is a full dump of the repo, a full checkout and a full replication to another server.
To start the move/splitting and for reference below is the current dir structure at the top level:
repository/
+---dir1/
+---dir2/
+---dir3/
Please note that this is the logical view of the repository not the subversion disk structure layout for it, where dir1.3 are a simple way of spliting the contents by areas/projects/subjects with no rules, which has been involved since the beginning in CVS.
My plan, as a starting point, is to move the top directories to their own repository, but also i want to kind of have multiple repositories served out of a single Subversion server.
A Subversion repository as standard looks like this:
repository/
+---conf/
+---db/
+---hooks/
+---locks/
Looking around the internet, google is your friends sometimes, and found a post that showed an example of how to have one Subversion server with multiple repositories, and kept the link to it, but today when wanted to read it, the domain was not longer working.
From what i remember was very simple post, but concise, and shared an idea on how to do it, so i when to the wayback machine, or better called Internet Archive, and pasted the url and managed to find a version of the url still in the archives.
From the post, it refers to the normal use of Subversion, where a single server will host a single repository, like i have in my current solution. Something like this:
# svnserve -d -r /home/svn/repository
And this is what i have at the moment, a big repository full of different things as stated at the beginning of this post, kind of separated by the top directory structure.
Currently split into three directories:
- copias - contains digital copies of most of my documents, bank statements, some invoices, and so on.
- freebsd - initial started this top directory to keep track of my configuration files for freebsd server.
- mufley - i believe the original start of the subversion server and migrated from CVS, but the top structure might have been changed. It contains most of the personal projects related to coding, learning and development of web server pages and alikes. In simple terms, a amalgamation of things.
In the post it is suggested to have a top level directory in the file system that will contain inside the different repositories, and every single repository will be a Subversion repository by itself.
But when inside the top level they will look like this:
repositories/
+---repo1/
+-------conf/
+-------db/
+-------hooks/
+-------locks/
+---repo2
+-------conf/
+-------db/
+-------hooks/
+-------locks/
...
In simple terms the start of the server will be like this:
# svnserve -d -r /home/svn/repositories
The new repository URLs will be something like this:
- svn://svnserver/repo1
- svn://svnserver/repo2
- ...
Et voila again, it seems to work.
This post is starting to be a bit long, so a good way to stop here and on the next part focus on the actual convertion/splitting the repository.