info-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem with merging branches


From: Derek R. Price
Subject: Re: Problem with merging branches
Date: Tue, 07 Aug 2001 09:51:41 -0400

Because a merge with a single static tag only selects revisions that contain
the tag.  You need two tags (calculated when useing a branch tag) so that CVS
can figure out which revisions are in the first set and not in the second and
delete them.  To make it a little clearer why this happens, if you merged the
changes from a single file onto the trunk, you wouldn't want all the rest
deleted because they weren't in the list.

This would work as well if CVS tagged dead revisions on branches when a branch
got tagged, I think, but to get that to happen, the operation of the tag
command would have to be changed dramatically.  Alternatively, I think you
could use the rtag command.

Derek

--
Derek Price                      CVS Solutions Architect ( http://CVSHome.org )
mailto:address@hidden         CollabNet ( http://collab.net )
--
I will not hide behind the Fifth Amendment.
I will not hide behind the Fifth Amendment.
I will not hide behind the Fifth Amendment...

          - Bart Simpson on chalkboard, _The Simpsons_

"Reinstein, Shlomo" wrote:

> Hi,
>
> I see a strange behavior of CVS (version 1.10.8).
> Let's say I create a branch of my CVS project, I develop the project on the
> branch, and commit to the branch several times. In one of the commits to the
> branch, I delete the file "a.c". Note that the file is deleted only from the
> branch, but remains on the trunk.
>
> At some point, I tag the version of the project on the branch, let's call
> this tag "branch_version_1". (Note that this is a specific version from the
> branch, but this is not the name of the branch.) And then I continue to
> develop the component on the branch.
> During the whole time, there are no changes to "a.c" on the trunk, it stays
> (on the trunk) as it was just before the branch.
>
> Now I want to merge everything that I made on the branch up to
> "branch_version_1" into the trunk. So I checkout the project (the latest
> version from the trunk), and I type:
>         cvs update -j branch_version_1
> I expect this merge to delete "a.c" from my working directory, given that it
> was deleted on the branch before this tag (branch_version_1), however, I
> found out that "a.c" remains in my working directory and is not scheduled
> for removal.
>
> I also noticed that when I use the name of the branch with the "-j"
> parameter, "a.c" does get deleted and scheduled for removal. Why isn't it
> deleted when the tag is not the name of the branch?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]