Using the SVN command line tool

Reprinted from: http://www.cnblogs.com/analyzer/archive/2009/08/25/1553424.html

Get the version of subversion for windows from http://subversion.tigris.org . After installation, there is svn.exe, a command-line-based client tool. Of course, there are also programs on the server side, so I don't care how to configure the SVN service here. The installer adds the path of svn.exe to the path environment variable, and we can use it by directly entering svn on the command line.

If you don't know how to use the svn command, you can query it as follows: svn help Know the subcommand, but don't know the usage of the subcommand, you can also query: svn help ci  common command for ci developers to import the project svn import http:// svn.chinasvn.com:82/pthread --message "Start project" to export the project svn checkout http://svn.chinasvn.com:82/pthread uses the export method to export a "clean" project svn export http: //svn.chinasvn.com:82/pthread pthread clears the field for failed transactions svn cleanup performs code modification locally, checks the modification status svn status -v svn diff update (update) server data to local svn update directory svn update file


























Add (add) local data to the server
svn add file.c
svn add dir

Rename and delete files
svn mv bc bb.c
svn rm dc

Submit (commit) local files to the server
svn commit
svn ci
svn ci -m "commit"

View some things related to the log
svn log directory
svn log file : 1. In the local file, each directory has a .svn folder (the attribute is hidden), which saves the relevant information. 2. Register the environment variable SVN_EDITOR as "E:\Program Files\Vim\vim71\gvim.exe". As a result, when svn ci is running, an error occurs: 'E:\Program' is not an internal or external command, nor is it runnable program or batch file. svn: Commit failed (details below): svn: system('E:\Program Files\Vim\vim71\gvim.exe svn-commit.tmp') return 1 Change SVN_EDITOR to "gvim.exe", and in path Add the path "E:\Program Files\Vim\vim71\", so that you can use vim to write comments when submitting. Attached:













Websites that provide free SVN services:
http://www.svnhost.cn/ (recommended)
http://www.chinasvn.com
http://www.javaforge.com
http://unfuddle.com
http://svn .coollittlethings.com/index.php (free for open source, fee for private projects)

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326397625&siteId=291194637