[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

little scripts to generate and apply diff series for Subversion

From: Liu Yubao <yubao.liu_at_gmail.com>
Date: 2007-01-09 04:56:40 CET

Hi,

I wrote two little scripts to generate and apply diff series for Subversion,
you need Subversion command line client and patch utility program to run it.
Windows users can download the latter from http://gnuwin32.sourceforge.net or
http://unxutils.sourceforge.net. I hope they are useful for you.

I know SVK can help decentralized development, but it hasn't pretty GUI frontend
now(no TortoiseSVK) and seems can't synchronzie between two Subversion repositories
easily.

Another similar tool I found is svnpush, but it seems not be maintained long time and
I guess it's a pain to install Perl modules in windows.

svn-patches.pl doesn't commit automatically because it's not easy to erase
your mistake in Subversion. It makes use of GNU patch, no 3-way merge is done,
so maybe it's not so convenient as you hope.

Below is a short scenario to show its usage.

----------------------------------------------------
reposA --- public repository
reposB --- private repository
svn export reposA/branches/something@2000
svn import reposB/branches/something@100
svn co reposB/branches/something
...work...commit...now it reaches revision 120

mkdir diffs;
perl svn-diffs.pl URL_to_reposB/branches/something 101 120

cd working_copy_for_reposA;
make sure the working copy is clean and updated;
svn lock reposA/branches/something -m "applying diff series, please wait..."

perl svn-patches.pl ..\path_to\diffs
...check...commit...run svn-patches.pl again until all patches are applied.

svn unlock reposA/branches/something
-----------------------------------------------------

regards,

Liu Yubao

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Jan 9 04:58:52 2007

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.