Is it right step by step and organization to create an SVN repo with multiple projects and providers?

I have read quite a lot of the Bean Software SVN Book Red Book, and some of the questions here on SO, but I want to make sure I'm going to do it right, the first time a step before I start using it. Is it correct?

  • Install SVN.
  • Create an SVN repository in / usr / local / svn. The directory structure is as follows:

    -- conf -- db -- format -- hooks -- locks -- README.txt 
  • Create folders through the command line to organize the repository (including projects and vendors).

     -- conf -- db -- format -- hooks -- locks -- projects -- project_name -- vendor -- trunk -- branches -- tags -- project_name -- vendor -- trunk -- branches -- tags -- README.txt 
  • Review the vendor code in the vendor folder under the correct project name.

  • Export the vendor code to the trunk under the correct project name (no merging is required since I do not have the project trunk files yet).
  • Create users / permissions in / svnroot / conf / passwd and / svnroot / conf / svnserve.conf.
  • Make sure svnserve is running, and on my local SVN client (TortoiseSVN) check the line for the project I need.

I do not need to show this at a public url, so I am not configuring Apache. The server is not on our network, but it is a dedicated CentOS box that we rent. Thanks for any thoughts and advice.

EDIT:

I assume I'm confused because I don't have code or a project to start with, so I start with the vendor code. Do I need to create a directory structure somewhere on the server that includes my project_name w / vendor subdirectories, trunk, branches and tags, import them into my repo, and then import the code from the provider into the supplier folder? The idea is that I can receive updates from the supplier, and then combine these updates with any changes that I have made to my trunk.

+4
source share
2 answers

Create folders through the command line to organize the repository (including projects and vendors).

Do you want to create a repository structure by creating directories inside the subversion installation directory? This is very wrong.

You need to create the necessary folders using the svn mkdir , and not through the file system.

In /usr/local/svn you have a physical implementation of the Subversion repository, and you should only access it through the client and never touch it manually.

For example, using the file scheme: // URL

 svn mkdir file:///usr/local/svn/projects -m "Parent dir for projects created" 
+6
source

You seem to have basically the right idea, but your terminology is a bit wrong. This really confuses SVN people as you use words that have specific meanings in the SVN context. To expand on what David said:

2) create your repository by doing something like svnadmin create /usr/local/svn .

3) create your folders. You do not need (or do not need) parts of your list that are not lower than projects/ . These other directories are what SVN uses to track changes; they are not actually in the repository. If you create a directory hierarchy somewhere on your system that contains the project_name/ subtree, you can run svn import on it as many times as you want, once for each project (each time specifying a different name for the destination). This will create your directory structure.

4) Instead of “checkout”, I think you mean either “import” or “checkin” (usually called “commit” in SVN, but “checkin” will be understood). Import will add the provider files to the repository. Checkout means "create a local copy of this version directory for me to work with," called a working copy. Each developer of your team must have their own working copy. After the developer makes changes to his working copy, they then svn commit changes to the repository by svn commit . Other developers on the team will run svn update to get these changes from the repository into their own working copies.

5) I have not read the SVN book recently, but I think that it instructs you to copy the version of the provider branch into the trunk, and not export it. Exporting in SVN terms means a non-version of the directory tree, which is clearly not what you want.

You can find something easier if you follow steps 6 and 7 right after step 2, since after that you can use the svn:// protocol to access your repository for the remaining steps instead of file:// , as suggested by Davide that only works on the local machine.

+5
source

All Articles