[cvsnt] Yet another obscure merge problem

Tony Hoyle tmh at nodomain.org
Thu Feb 26 15:54:17 GMT 2004


On Wed, 25 Feb 2004 15:14:26 -0000, "Harrison, Andrew"
<andy.harrison at anite.com> wrote:

>Ok, at least we now agree what is supposed to happen! Sorry, maybe I wasn't
>explaining it very well earlier. Now we just need to find out why it's not
>working for me. This is what I'm doing, as you can see the Branch1->Branch2
>merge creates a new version of file1.c:
>
>Current files, both at rev 1.1:
>C:\mergetest\file1.c
>C:\mergetest\file2.c
>
>Commands all issued in directory C:\mergetest\
>
>cvs tag -b Branch1
>cvs remove file1.c
>cvs commit -m "no message"
>cvs tag -b Branch2
>cvs update -r Branch2
>cvs update -jBranch1
>cvs commit -m "no message"

That's correct...

You've created branch1 at rev 1.1 in file1.c
Them removed file1, and committed it for rev 1.2
Branch2 is not added to file1 (since it doesn't exist) so when you
update to it you get no file1 because it doesn't exist on that branch,
*not* because it was deleted.
You then merge with branch1, which has rev. 1.1 of file1, which
exists.  This causes file1 to appear on Branch2 in its rev 1.1 state.

If you do an rtag at the 4th step instead of tag you'll get a
different result (possibly what you wanted).

Tony




More information about the cvsnt mailing list