Create SVN service on the local machine in Windows

Source: Internet
Author: User
Tags tortoisesvn

For a small project, you need to create the svn service on your PC. In order to make it simple, you didn't use Apache. Previously, you only used the client and didn't create the server. It took a morning to complete the process. The main function of SVN is used for team development. It is used to handle version control and concurrent modification conflicts of source code modifications. Of course, there is no need to create a person during development.

Note: Visual SVN is not used.

I. Software Download

1. server software subversion, I use version 1.6.6, Setup-Subversion-1.6.6.msi

2. Client Software tortoisesvn 1.6.6

Note: The software versions on the server and the database must be the same; otherwise, the access will fail.

Ii. Installation

1. Server Side

Download the server software, double-click the Setup-Subversion-1.6.6.msi to run the installationProgramThere is nothing to say about this. It is good to go all the way to next, so the default installation directory is my c: \ Program Files \ subversion \.

2. Client

Like on the server side, double-click tortoisesvn 1.6.6 after downloading and install tortoisesvn. However, make sure that the client and server versions are consistent.

3. Create a local repository

Repository is the centralized storage of source code. The source code submitted after all modifications is saved here, and all the modified versions, branch versions, version merge, and concurrent modification processing are recorded. For example, if I place the source code library in D: \ svnroot \ myproject (note that it cannot be deleted), right-click the folder and choose tortoisesvn-> Create repository here. After the creation, some directories and files are automatically generated under this directory, such:

Iv. Configuration

You only need to configure the server side for configuration. Open the Directory D: \ svnroot \ myproject \ conf \. There are three files to change: authz, passwd, and svnserve. conf.

1. authz File

Create a user group, such as group1, which has three users: user1, user2, and user3. The permission is RW, that is, read and write permissions.

2. passwd file, used to change the User Password

The initial passwords of the three users are set to 123.

3. svnserve. conf file

You need to change the following lines and remove the comment # in front of each line, as shown in figure

Change

Note: realm must be specified as our source code version library. Here it is myproject.

5. Start server services

You can use the command lineSvnserve.exe-D-r d: \ svnroot, there is no response after you press enter, but you cannot close the command line window. If you disable the service, it will be terminated.

After starting the service, we can test it. Open a file browser, right-click tortoisesvn-> repo-browser, and install the client program tortoisesvn.

Enter the repository address of the server.

Click OK. If the following window is displayed, the installation and configuration are successful.

In this way, you can access the client with the three users configured earlier. Note that you must change 127.0.0.1 to the local IP address when accessing other machines, we will not introduce how to use the client here.

Vi. Supplement

We started the svn service using the command line window. The window cannot be closed, which is very inconvenient. Next, let's talk about how to put the service in the Windows Service so that it will automatically start after it is started.

Download a svnservice.exe file and copy it to the directory where c: \ Program Files \ subversion \ bin \ Program is located. Run the command as shown in Figure

Then we canYou can see this service in Windows Service and change it to automatic start. This will automatically start SVN service every time you start the system.

If anyone has a more concise method or finds anything inappropriate, leave a message for me. Thank you.

(End)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.