[Top][All Lists]

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

Re: Question regarding merging

From: Mark Hoogenboom
Subject: Re: Question regarding merging
Date: Mon, 05 Dec 2005 12:04:58 +0000
User-agent: Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.7) Gecko/20041221


Message: 4
Date: Thu, 01 Dec 2005 15:11:30 -0500
From: Jim Hyslop <address@hidden>
Subject: Re: Question regarding merging
To: Norman Crisp <address@hidden>
Cc: address@hidden
Message-ID: <address@hidden>
Content-Type: text/plain; charset=ISO-8859-1

Hash: SHA1

Norman Crisp wrote:
Could someone please confirm that my steps to performing a merge from a
branch to trunk is correct.

1- fresh checkout of the trunk into an empty sandbox
        - cvs checkout -P -kk module-name
2- update from the branch into the checked out trunk sandbox
        - cvs update -kk -P -jlatest-good-tag-from-the-branch
3- resolve and conflicts that may have occurred
4- commit all changed files back into the truck

Historically I have found conflicts that are not really conflicts due to the
Revision keyword.  This is why I specify -kk on both the initial checkout
from the trunk and also on the update from the branch.  Although the results
look correct, I am not %100 certain that this is the correct method.

That is one correct way to do it. To expedite future merges, you need to
apply a second tag:

cvs rtag -rlatest-good-tag-from-the-branch last-merge-point

(I am assuming latest-good-tag[etc.] is a non-branch tag, if not, then
you need to apply a non-branch tag and re-do the merge specifying that
new tag).

In subsequent merges, you then specify two -j options:
cvs update -kk -jlast-merge-point -jeven-later-good-tag-from-the-branch

then, when the merge is committed, move 'last-merge-point':

cvs rtag -F -reven-later-good-tag-from-the-branch last-merge-point

- --
Jim Hyslop
Dreampossible: Better software. Simply.
                Consulting * Mentoring * Training in
   C/C++ * OOD * SW Development & Practices * Version Management
Version: GnuPG v1.4.2 (MingW32)
Comment: Using GnuPG with Thunderbird -


I guess this is all quite elementary, but could you repeat your answer in slow-motion? I assume that after step 1 the sandbox contains the latest revisions from the trunk. But then if latest-good-tag-from-the-branch is a tag on the trunk, what does step 2 do? How do we end up with revisions from the branch in the sandbox to commit?

Another (related) question: is it possible to merge the trunk with a branch instead of the other way around? That is, the branch will contain changes in the trunk since the branch was created, but the trunk won't contain the changes on the branch.

Can someone enlighten a newbie? Thanks a lot.


reply via email to

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