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

Re: SVN Copy Question...

From: Dave Lawrence <dlawrence_at_ad-holdings.co.uk>
Date: Tue, 23 Dec 2008 07:38:35 +0000

BRM wrote:
>
> Is there a way to do the svn copy/move and overwrite an existing file in the same transaction? (i.e. instead of having to go delete the file first, then do the copy/move second, do it as a single commit, or have the copy/move comit the changes between the two files as the commit..).
>
Yes because you don't have to commit the deletion before you commit the
copy / move.

eg:
> C:\SVN\tests\test_wc2\dir1>svn del file1.c
> D file1.c
>
> C:\SVN\tests\test_wc2\dir1>svn mv file2.c file1.c
> A file1.c
> D file2.c
>
> C:\SVN\tests\test_wc2\dir1>svn status
> R + file1.c
> D file2.c

R + indicates file1 has been replaced. Note that after you commit it,
the "new" file1.c will have the history of file2.c

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=990417

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2008-12-23 22:02:43 CET

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.