Introduction to svn commands in CentOS

Source: Internet
Author: User
Tags svn client svn update

Introduction to svn commands in CentOS
Introduction to CentOS-SVN commands

Server Operating System: LinuxCentOS_6.7_x64

Install SVN

Yum install svn

SVN installation overview

After installing svn, the server has three commands:

Svnserve svn server commands

Svnadmin svn administrator command

Svn client commands

Start SVN

Svnserve-d-r/data/svn/repository

# Start the svn service using the specified directory as the root directory

Create svn version Library

Svnadmin create/data/svn/repository/MyP01

# Create a svn library in the specified directory, which should be under the svn service root directory

Edit SVN repository Configuration

Cd/data/svn/repository/MyP01/conf/

The newly created svn library will automatically generate a conf folder and three files under the specified directory: conf/authz, conf/passwd, conf/svnserve. conf: svn authentication information, svn account password, and svn service configuration

You can change the file name and path of the first two, which are specified in svnserve. conf.

Edit svnserve. conf

Find

# Password-db = passwd

# Authz-db = authz

Cancel the preceding # comment to specify the authentication data storage file;

Find the line # anon-access =, which determines the permission for anonymous access to a certain extent, change to anon-access = none (it seems that svn log information cannot be viewed if this is not changed ).

Auth-access determines the authorized user's access permission to a certain extent, but this seems useless when the account and password files are specified;

Realm = My First Repository specifies the alias of the svn library. It is best to change it by yourself. Otherwise, a random code is used;

Others, omitted;

Edit authz

This file determines which users/groups have permissions on the directories in the database.

Example:

[/]

Seraph_fd = rw

* = R

Indicates that seraph_fd users have read and write permissions for the root directory, and any users (including tourists) have read permissions;

Append the above content to the end of autz.

I did not check the complexity;

Edit passwd

This file determines the access passwords of those users.

Example:

[Users]

Seraph_fd= 1234

I did not check the complexity;

Export SVN Project

Svn checkout svn: // 127.0.0.1/MyP01/data/P01

# Export the specified svn Library to the specified directory

Update SVN copy

Svn update/data/P01

# Update the specified copy to the latest version.

Svn update/data/P01-r 50

# Update the specified copy to the specified version number (50)

Others

Svn revert/data/P01

# Restore a specified copy

Svn commit/data/P01-m' test submission .'

# Submit the specified copy and specify the version log

Last

Remember to update SVN before modification to avoid unnecessary conflicts;

For instructions, use the help or -- help parameter to obtain instructions. For example:

Svnadmin -- help

Svn update -- help

Svn command. Check the common parameter -- username -- password, for example: svnupdate/data/P01 -- username seraph_fd -- password 1234.

For more information, use -- help.

* Some understandings may be biased, but they can be used in tests.

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.