Ubuntu svn Install & Use & commands

Source: Internet
Author: User
Tags diff svn update

Svn
    • Installation
Install Subversion
    • Checkout
SVN checkout svn://192.168.1.110/app

Enter the appropriate user name and password as prompted.

    • Add a new file to a repository
SVN add *//(add all C files in the current directory)
    • Commit the changed file to the repository
SVN commit-m "My Commit"  test.  CPP
    • deleting files
SVN Delete svn://192.168.1.100/app/php/helloworld.php-m "Delete file"
    • Help
SVN help chechout  Checkout (CO): Check out a working copy from a repository. usage:checkout url[@REV] ... [PATH]
SVN common commands
    • Checkout
svn Checkout Path (path is a directory on the server) // For example: SVN checkout svn: // 192.168.1.100/app/
    • Add a new file
file // Example: SVN add test.php (add test.php)
    • Commit the changed file to the repository
SVN commit-m "LogMessage" [-n] [--no-unlock] PATH (if hold lock is selected, use –no- unlock switch)// For example: SVN commit-m "a DD test file for my test "test.php
    • Locking/unlock
SVN lock-m "Lockmessage" [-Force] PATH// Example: SVN lock-m "lock test File" test.php
    • Update to a version
SVN update-R m Path// For example://SVN Update If there is no directory behind it, the default is to update all files in the current directory and subdirectories to the latest version.  //svn update-r test.php (Restore file test.php in repository to version)//SVN update test.php (update, Synchronized with the repository. If the prompt expires at the time of submission, it is because of the conflict, you need to update, modify the file, then clear the SVN resolved, and then commit the commit)
    • View file or directory status
SVN status path (status of files and subdirectories under directory, normal status not shown) // "?: Not in SVN control; M: Content modified; C: conflict; A: Scheduled to be added to Repository; K: Locked"
SVN status-v path (show file and subdirectory status)// The first column remains the same, the second column shows the work version number, the third and fourth columns show the last modified version number and the modifier.  // Note: The SVN status, SVN diff, and SVN revert three commands can be executed without a network, because SVN retains the original copy of the local version in the Local. SVN. 
    • deleting files
SVN Delete path-m "Delete test fle"// For example: SVN delete svn://192.168.1.100/app/ Php/test.php-m "Delete test file"// or directly svn delete test.php and then svn ci-m ' delete test file ', this 
    • View Logs
SVN log path // For example: SVN log test.php shows all changes to this file, and its version number
    • View file Details
Info Path // Example: SVN info test.php
    • Compare differences
diff path (compares the modified file to the underlying version) // example: SVN diff test.php diff -r m:n Path (difference between version m and version N)// For example: SVN diff-r 200:201 test.php
    • Merging differences between two versions into the current file
SVN merge-r m:n Path/// For example: SVN merge-r 200:205 test.php (The difference between version 200 and 205 is merged into the current file, but there is a general conflict that needs to be addressed)

Restore Local modifications

svn revert: Restores the original unchanged working copy file (restores most of the local modifications). revert:// Note: The notebook command will not access the network and will release the conflicting condition. But it does not restore the deleted directory
I'm the dividing line of the king of the Land Tiger.

Ubuntu svn Install & Use & commands

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.