Scenario: Merging all changes made on a subbranch

The following scenario is an example of a situation that requires merging of all changes made on a subbranch. Merging all changes made on a subbranch is the simplest and most common scenario.

The figure shows merging all changes from a subbranch. The element opt.c has version 4 to 8 on the main branch, with branch r1_fix off version 4 that has versions 0 to 6. Versions 1 to 6 are being merged from the r1_fix branch as shown by a merge arrow to the checkout of version 8 on the main branch, which is the target version.

Bug fixes for an element named opt.c are being made on branch r1_fix, which was created at the baseline version RLS1.0 (\main\4 on the Windows® system or /main/4 on the UNIX® system). Now, all the changes made on the subbranch are to be incorporated into main, where a few new versions have been created in the meantime.

Task overview

Merging the changes from the r1_fix branch involves the following tasks:
  • Preparing a destination view

    The view must select the target version, which, in the figure, is opt.c@@/main/8.

  • Finding changes

    Use the Merge Manager or the cleartool findmerge -merge -gmerge command.

  • Merging changes

    Use Diff Merge to resolve any conflicting differences between merge contributors.

  • Testing and checking in merge results

    Test the merge results in the view you accessed. Then check in the target version (which contains the results of the merge).

Related concepts
Scenario: Selective merge from a subbranch
Scenario: Removing the contributions of some versions
About recording merges that occur outside Rational ClearCase control
Related reference
clearmrgman
findmerge

Feedback