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

Re: Merge files from a moved directory

From: Stefan Sperling <stsp_at_elego.de>
Date: Wed, 30 May 2012 12:22:23 +0200

On Sun, May 27, 2012 at 05:30:25PM -0300, Emiliano S wrote:
> Hi,
>
> Suppose there's a directory with a single file in it:
>
> dirA\foo.c r10
>
> While I'm modifying this file someone else modifies the file,
> renames dirA to dirB and commits.
>
> dirB\foo.c r11
>
> Before committing I try to update and get a tree conflict, status
> shows this:
>
> A + C dirA
> > local edit, incoming delete upon update
> M + dirA/foo.c
>
> Now I have dirA and dirB in my working copy.
> Is there any graceful way to make subversion merge my file with the
> newest version?

Not automatically. You currently have to merge outstanding changes
into files manually. Either by editing files to apply local uncommitted
changes to a different file, or using a command suc as
  svn merge -cN URL/TO/FILE path/to/other/file
to merge changes that were already committed in revision N.

In some cases 'svn diff' and 'svn patch' (new in Subversion 1.7) can
make moving local changes between files a bit easier.

> What if instead of a single file there are many?

Then your manual merging will take more time.

It is clear that the current situation isn't ideal. Work is underway to add
interactive conflict resolution for tree conflicts in some future release.
I cannot give you a specific ETA at this point however. Feel free to jump
in and help out!
Received on 2012-05-30 12:23:04 CEST

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