How can I apply a label to elements selected by a particular configspec rule in ClearCase?

681 Views Asked by At

I need to apply a label to a particular set of elements in a VOB that are selected by a line in my configspec. I have other lines as well, in my configspec.

For example, let's say here's my configspec.

element * .../bugfixesApril/LATEST
element * WORK122014_v2

How do I apply a label on the set of elements that get selected by the bugfixesApril/LATEST rule?

There are cases where the parent folder is not selected by the same rule, and the elements on which the label is to be applied do not lie in the same location. They are spread throughout the VOB

I have a csv file containing the list of files with complete path (including version number) where the label is to be applied

1

There are 1 best solutions below

10
VonC On BEST ANSWER

The easiest solution is to have another view (preferably dynamic one) with only the right selection rules in order to select only the version you want.

You would then use that view for your cleartool mklabel command.

To be sure to label only the files, and not the parent folder, you can combine mklabel to a cleartool find directive similar to "How can I find all elements on a branch with version LATEST that has no label applied?".