Branching in ClearCase?

When I want to use a branch in CC, I usually add something like this in the configuration specification:

element * .../first_branch/LATEST element * .../Main/LATEST -mkbranch first_branch element * ../Main/LATEST 

Now I want to create a branch that is a child of the first. Let's say it's called second_branch (today I'm creative). What does this configuration look like?

+4
source share
2 answers

Like this:

 element * .../second_branch/LATEST element * .../first_branch/LATEST -mkbranch second_branch element * .../Main/LATEST -mkbranch first_branch element * ../Main/LATEST 

Now your presentation will look like the latest version on second_branch or, if it doesn’t exist, the latest version on first_branch or, if it doesn’t exist there, the latest version in the main branch. After checking the file, a new version element will be created on second_branch and first_branch respectively.

I don’t have access to the ClearCase instance right now, so I can’t double check your last two lines, but I think you probably meant it instead?

 element * .../second_branch/LATEST element * .../first_branch/LATEST -mkbranch second_branch element * /Main/LATEST -mkbranch first_branch 
+4
source

To add to Kim’s answer, I prefer to start a branch with a label than the LATEST versions selected by the branch.
That way, I know what “ second_branch ” means and where it comes from.
(coming from the LATEST another branch means that it comes from a moving point that represents something else over time)

 element * .../second_branch/LATEST element * A_LABEL -mkbranch second_branch element * .../first_branch/LATEST element * .../Main/LATEST -mkbranch first_branch element * ../Main/LATEST 

If you set A_LABEL for the customized view:

  • in LATEST from first_branch '
  • in a "stable" state

you can branch out from a known point.

+5
source

Source: https://habr.com/ru/post/1334768/


All Articles