Cleartool findmerge select changes from file 2 by

2019-05-29 12:09发布

问题:

So I have a branch is that is dreadfully out of date with the rest of the world. I'd love to simply create a new branch and merge over... but that task would be even larger... anyways what I'm trying to figure out is if I can set findmerge to always accept file 2. To speed my merge up, I initially did:

cleartool findmerge <path to out of date code> -ftag <my merge from view> -merge -abort

to cover all the simple merges, but not I want to grab the 'conflicting' changes, but I really just want all changes from from 'file 2'.

Is there an easy way or flag to provide to findmerge to do that?
Or do I have to go file by file and choose each change individually?

At the end of the day, I want what is an branch that has for a specified folder what is exactly in the merge from area.

I'm guessing the answer is 'no' but I have hope, and my figures are getting tired of pressing the return key :-)

回答1:

For that kind of "reset" merge, where you want one branch content to (after merge) mirror the content of the source of that merge (2), I don't use findmerge at all.

I set an activity (if I am on UCM), and I initiate a clearfsimport in order to import data from the source view to the destination view.

I then create merge arrows between any visible version of the source view and their matching element in the destination view (as in "how to ignore files when finishing private ClearCase branch?", or "Merge arrow in ClearCase" -- that is the red merge arrow --, also used in "How to perform a trivial merge of a binary file in a ClearCase VOB")

cleartool merge -ndata -to aFile -version /main/a/SourceVersion /main/a/DestVersion

That way, one source branch has been merged to the destination, and the source content has been copied over the destination view content.