[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Overwriting trunk files with specific branch files
From: |
Jim Hyslop |
Subject: |
Re: Overwriting trunk files with specific branch files |
Date: |
Wed, 17 Aug 2005 12:34:07 -0400 |
User-agent: |
Mozilla Thunderbird 1.0.2 (Windows/20050317) |
Andy Jones wrote:
cvs co -j HEAD -j t_branchA_tagA module
Does anyone feel like explainaing how this is not a merge? I don't get it.
It is a merge command, but it does not merge the changes from the
branch. It will overwrite the head with the branch.
The command as shown is a shortcut to:
cvs co module
cd module
cvs up -j HEAD -j t_branchA_tagA
"cvs up -j REVA -j REVB", the merge command, applies the delta between
REVB and REVA to the current directory. For a normal merge, REVA and
REVB are normally on the same branch, thus you would get the changes
from the branch merged into the changes on the trunk, i.e. trunk = trunk
+ branch. But, in this case, REVA and REVB refer to the tip revisions on
two different branches. The delta is Branch-HEAD, which when added to
the HEAD, results in Branch.
Mathematically, this can be expressed as:
CWD = CWD + Delta
where CWD is the current working directory, and Delta is REVB - REVA. In
this example CWD is HEAD, REVA is HEAD and REVB is Branch, so the
equation becomes:
CWD = HEAD + Branch - HEAD
which simplifies to
CWD = Branch
It takes a bit to wrap your head around it, but it does work and do
exactly what Christopher wanted.
--
Jim
- Re: Overwriting trunk files with specific branch files, (continued)
- RE: Overwriting trunk files with specific branch files, Christopher.Fouts, 2005/08/16
- RE: Overwriting trunk files with specific branch files, McNamee, John, 2005/08/16
- RE: Overwriting trunk files with specific branch files, McNamee, John, 2005/08/16
- RE: Overwriting trunk files with specific branch files, Christopher.Fouts, 2005/08/16