Recently, due to the requirements of the lab, the teacher decided to build an independent SVN server. She had never used SVN before, so she began to learn how to build an independent SVN server from scratch.

SVN is an open source version control system that uses a branch management system. To put it simply, SVN is used for multiple people to jointly develop the same project and share resources.

The SVN server can be run in two modes: independent server and Apache server. The two ways have their own advantages and disadvantages, and this is the form of an independent server.

The steps for setting up an independent SVN server are as follows:

  • Install VisualSVN server on a computer
  • Install TortoiseSVN on another computer
  • The TortoiseSVN connects the TortoiseSVN to the VisualSVN server to complete the connection test

Download and install VisualSVN server

VisualSVN Server is an integrated SVN Server tool, and includes MMC management tool, is a rare good tool SVN Server.

We can first install VisualSVN Server, run VisualSVN Server Manger, then create a new code base, set up some security, and finally create a user.

  • VisualSVN ServerDownload address:www.visualsvn.com/server/down…

  • Installing VisualSVN Server

  • Agree to installation agreement

  • chooseVisualSVN Server and Administration Tools, and add command line tools to system environment variables

  • chooseStandard EditionStandard version installed, free version but with fewer features

  • LocationThe installation position,RepositoriesThe code repository location,Server PortThe service port, port 8443

  • Waiting for the installation

  • The installation is complete

At this point, the SVN server is installed successfully, and the next step is to create the repository

  • Open theVisualSVN Server MangerAnd right – click To create a new repository

  • Select a repository based on FSFS file system format storage

  • Give the repository a name, in this case Test

  • New Empty warehouse

  • All users have read and write permissions

  • I click Create and I Create an empty warehouse, and there’s nothing in it, right

  • Next, create a new user for the test

  • Simply name and set the password, and click OK to complete the user creation

  • After both the test repository and the user are created, copy the URL of the repository

  • Access it in a browser using the copied URL and log in as the user you just created

  • You can access the empty folder you created earlier

At this point, the SVN environment setup on the server side is complete.


Download and install TortoiseSVN

TortoiseSVN is a free and open source client for SVN version control, which can manage files and directories over time. Files are stored in a central repository, which is much like a normal file server, except that it remembers every change to a file or directory.

  • TortoiseSVNDownload address: https://tortoisesvn.net/downloads.html
  • After downloading, click Install, the installation process is very simple, always clickNextjust

TortoiseSVNAfter the installation is complete, right-click the relevant function menu will appear

  • Click on theRepo-browserInstant browse repository

  • Enter the URL of the server:IP address + port number. The port number is the front installationVisualSVN ServerEnter https://192.168.10.39:8443/svn

  • chooseAccept the certificate permanently

  • You need a user password to log in, and use the test user you created earlier

  • As you can see, throughTortoiseSVNAfter successfully connecting to the empty repository Test on the SVN server on the other computer, we can add code to it, create folders, and so on.


conclusion

Through the above steps, we successfully set up an independent SVN server with two computers and tested it successfully. However, SVN, as a version control system second only to Git, still has many functions to learn, and the operations shown above are just the tip of the iceberg.