ClearCase time and query

2019-01-15 20:40发布

This config-spec show the files I need:

element -dir * '{version(/main/LATEST) && !version(SLT-T)}'
element -file * '{version(/main/LATEST) && !version(SLT)}'

Now I need to see how the source looked at some point in the future, so I do this:

time 01-Nov-2008
element -dir * '{version(/main/LATEST) && !version(SLT-T)}'
element -file * '{version(/main/LATEST) && !version(SLT)}'

Unfortunately this still shows me "the present". The manual says:

Time rules may be nested. They may not include any query language constructs.

Okay, but what do I do then?

How do I exclude files and directories with a certain label, without using query language? Or is there way to specify time in the query language?

(No files has a SLT-T label, and no directories has a SLT label.)

1条回答
做个烂人
2楼-- · 2019-01-15 21:25

Did you try adding some query-language directives like:

&& !ver{created_since(1-Nov-2008)}
&& ver{created_since(1-Nov-2008)}

(all the versions existing before/after 1 Nov. 2008)

That is part of the query language and may help you refining your selection rules.


I confirm for having tested it:

element /myPath/... /main/{!created_since(01-Sep-2008)}
element /myPath/... /main/LATEST

would give you all version created before September the first in this instance.

I am not sure it can be combined with your rules to successfully achieve what you are looking for, though.

My point was just to make sure you can include time-based selection rules in your config spec.

查看更多
登录 后发表回答