Show the diff of last commit in svn
Answer:
Someone has just committed their changes to the svn and you want to find what have changed, just use the command:
# svn diff -rPREV
Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.
Show the diff of last commit in svn
Answer:
Someone has just committed their changes to the svn and you want to find what have changed, just use the command:
# svn diff -rPREV
Remove SVN client credentials caching
Answer:
svn will store your credentials information at "~/.subversion/auth/svn.simple/" for caching to help you from typing password on every svn commands. In order to clean this cache, you can
# rm -f ~/.subversion/auth/svn.simple/*
Show svn log for a particular folder
Answer:
To show the svn log for a particular folder, just need to use..
# svn log /data/foo
------------------------------------------------------------------------
r1935 | [email protected] | 2011-11-23 19:05:43 +0800 (Wed, 23 Nov 2011) | 1 line
Fixed the crash issue (Jira 2001)
------------------------------------------------------------------------
r1934 | [email protected] | 2011-11-23 18:47:54 +0800 (Wed, 23 Nov 2011) | 1 line
Added missed files
How to merge a branch back into trunk using SVN
Answer:
To merge a branch back into the trunk using SVN: (Assume your local corresponding folders are branch and trunk)
1. Get the revision number at which the branch was created
# cd branch
# svn log --stop-on-copy
2. Get the head revision number of your trunk
# cd trunk
# svn update
3. Merge in action
# cd trunk
# svn merge -r <BRANCH_CREATION_REVISION_NUMBER>:<HEAD_REVISION_NUMBER>
http://example.com/svn/repos/demo/branches/<MY_BRANCH> .
Revert all local changes in SVN
Answer:
Too revert all local changes in your current SVN repository, you can run the following command
# svn st -q | awk '{print $2;}' | xargs svn revert
That is it.