Config spec rules for elements in subbranches

The following is an example of a config spec that isolates work from the main branch by creating a subbranch called bug-fix:


element * CHECKEDOUT
element * .../bug-fix/LATEST
element * BASELINE-X -mkbranch bug-fix
element * /main/0 -mkbranch bug-fix 

Rule 1 (first line) selects checked-out versions in your view.

Rule 2 (second line) selects the latest version on the bug-fix branch.

Rule 3 (third line) selects the version labeled BASELINE-X. When such a version is checked out, the bug-fix branch is created.

Rule 4 (fourth line) determines that when a new element is created, the mkbranch clause causes the new element to be checked out on the bug-fix subbranch which is created automatically with the mkbranch command. Also, if an existing element does not have a bug-fix branch or a version with the BASELINE-X label, the bug-fix branch is created when you check out the element.