I was really hoping somebody would contradict me on this and say, 
"Don't be an idiot, there's an easy way to do it!"  Is the truth 
really as bleak as I painted it?  Can it really be true that if you 
have binary files and text files in your repository, and there are 
keywords in your text files, there is no single cvs command that will 
merge onto a long-lived branch, avoiding spurious conflicts?  (Even 
if you are careful to tag the source of every incremental merge?)

At 7:56 AM -0400 4/14/00, Dave Makower wrote:
>Things become even worse if (a) there are any binary files in your 
>module, and (b) you use keywords like $Id$, $Name$, etc., in your 
>text files.  The keywords cause spurious conflicts on every merge 
>after the first (if those text files have been modified on the trunk 
>since the previous merge out to the branch).  One solution to this 
>is to do your update with the -kk flag, but if you have any binary 
>files in your repository, -kk will corrupt them.  Additionally, the 
>-kk flag is sticky, and if you commit files with this flag, they 
>will be marked with the -kk flag in the repository, affecting other 
>people's workspaces, even those not on the branch.  Even worse, 
>there's no way (that I know of) to clear the sticky flags from your 
>branch workspace and go back to the default, without blowing it away 
>and checking it out from scratch (the -A option will clear your 
>branch tag).  If you do an update with -kkv (the default for text 
>files), then _that_ becomes explicitly sticky, which is still not 
>what you want (and again, the binary files will suffer).
>
>We tried doing the following in a branch workspace, but it didn't 
>help; we still got the spurious conflicts (using cvs 1.10.8, with a 
>local repository, i.e., non-client-server):
>
>   $ cvs update -W"'*' -k 'k'" -jtrunk-tag-at-merge-1 -jtrunk-tag-at-merge-2
>
>Anyone have a solution for this problem?
>
>I can think of two nice-to-haves here:
>
>1) It would be nice if CVS provided an option for update that would 
>use '-kk' (without making it sticky) on files without explicit 
>sticky tags, but respect any existing '-kb' flags.  Maybe '-km' for 
>'merge'.
>
>2) If, in a branch workspace, you temporarily check files out with 
>non-default -k options, and you want to set them back to the 
>default, it would be nice to be able to say something like 'cvs 
>update -Ak', and have it set the flags back to normal, to avoid 
>checking your files back into the repository with the sticky flags.

-- 
+-------------------------------------------------------------------+
| Dave Makower                                 <[EMAIL PROTECTED]> |
| Manager of Portal Architecture & Development                      |
+--------------------------------+----------------------------------+
|   iClick, Inc.                 |   (914) 872-8030                 |
|   120 Bloomingdale Road        |   (914) 872-8100   fax           |
|   3rd Floor                    |   (914) 872-8000   main          |
|   White Plains, NY  10605      |   http://www.iclick.com/         |
+--------------------------------+----------------------------------+

Reply via email to