In a ClearCase config spec, can I make an include statement use the rules already specified?

StackOverflow https://stackoverflow.com/questions/22102811

  •  18-10-2022
  •  | 
  •  

Question

I'd like to have a ClearCase config spec that has this:

element /path/dut.csp  /main/RELEASE_42
include /path/dut.csp

The problem I am encountering is that the include statement will include the version of the dut.csp file that is visible in the view before this config spec was set. It does not take into account the element rule the line before.

Sure I can call cleartool setcs -current, but what if this sort of approach is used again in the included csp file? How many times do I have to do this before the view is stable?

At the moment I am specifying @@/main/RELEASE_42 on the include statement as well. But then I have to edit both lines when I change the version. Also, if I want to checkout the csp file for development I then also have to edit my config spec to use the checked-out version.

Is it possible to use the include statement without a revision specification and have the earlier rules in the config spec evaluated before the include statement?

I am using ClearCase version 8.0.0.7.

Was it helpful?

Solution

No, it doesn't seem possible, considering the way selection rules are evaluated in a config spec.

That means you need to use:

  • a dedicated view to select the right version of that file
  • another view to use that include referring the file of the first view
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top