Set up and use the SVN version management environment in Xcode under Mac OS X

Source: Internet
Author: User

InMac OS XUnderfloor setup and useXcodeMediumSVNThe version management environment is described in this article, and Leopard has been built inSvnYes, so all you need to do is configure. You can use svnadmin-vsersion to view the details.

1. Create a directory to save the software repository. Enable Web Sharing (Apache2) in the system settings ).

 
 
  1. Sudo su (then enter the password)
  2.  
  3. Mkdir/opt
  4.  
  5. Mkdir/opt/svn
  6.  
  7. Mkdir/opt/svn/repos

The directory/opt/svn/repos/is created/

2. create a version repository svn create/opt/svn/repos

3. Modify the authorization Configuration

Go to the repository configuration directory cd/opt/svn/repos/conf

(1) edit the configuration file vi svnserve. conf to cancel the comments of the following lines.

 
 
  1. Anon-access = read
  2.  
  3. Auth-access = read
  4.  
  5. Password-db = passwd (password configuration SAVING file)
  6.  
  7. Auth-db = authz (authentication configuration SAVING file)

Image address: http://www.gothisway.org/blog/wp-content/uploads/2010/05/Xcode-SVN.png

(2) edit the password configuration file vi passwd

Format: "user name = password"

(3) edit the authentication file vi authz

Format: [groups]

User Group name = user group member

[Directory to be authorized]

@ Group name = permission

User name = permission

For example:

 
 
  1. [groups]  
  2. g_developers = jcccn,jesse,bill  
  3. g_tester = jerry,wang  
  4. [/]  
  5. @g_developer = r  
  6. jcccn = rw 
  7. * =  
  8. [/jcccn]  
  9. @g_tester = rw 
  10. jcccn = rw 
  11. * = r 

(4) Configure to ignore the file vi ~ /. Subversion/config

Find the global-ignores line, remove the comment, and edit it

 
 
  1. global-ignores = build *~.nib *.so *.pbxuser *.mode *.perspective* 

Find enable-auto-props = yes and remove the comments. declare the following text file in [auto-props] Section:

 
 
  1. *.mode* = svn:mime-type=text/X-xcode  
  2. *.pbxuser = svn:mime-type=text/X-xcode  
  3. *.perspective* = svn:mime-type=text/X-xcode  
  4. *.pbxproj = svn:mime-type=text/X-xcode 

4. Start svnserve:

 
 
  1. svnserve -d -r /opt/svn/repos 

Killall-9 svnserve can be used to end the service

5. Configure SVN in Xcode

(1) Select SCM> Configure Repositories from the Xode menu, click the plus sign on the left, enter the repos Name in Name, select subversiion in SCM, and enter the SVN server information.

 
 
  1. Name: repos Name, for example, jcccn
  2.  
  3. Scheme: svn
  4.  
  5. Host: Host address, for example, 192.168.1.104
  6.  
  7. Path: Path such/
  8.  
  9. User: User Name
  10.  
  11. Password: Password

(2) Select SCM-> Repositories to create a folder. The daily management of SVN can also be done here. Click Import and select the project for version control.

(3) Check out! Select a project, click Check out, and select the target location. It is equivalent to initializing the project with svn and adding some control information. This step is very important. If it is missing, version control will not be available.

(4) Open the project after Check out, click the project property Get info, and select SCM Repository as your configuration in general.

(5) After setting, you can see a new column in your project view. M indicates that the file has been modified, and then you can use the SCM menu, you can also right-click the menu to directly perform SVN operations, such as commit, update, revert, diff, and log. For commit, it is best to enter the details of the message version with respect to the previous version.

Summary: InMac OS XUnderfloor setup and useXcodeMediumSVNThe version management environment has been introduced. I hope this article will help you!

Related Article

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.