使用mkelem时,新元素会出现在哪里? [英] Where do new elements appear when mkelem is used?
问题描述
我的配置规范设置为:
element * CHECKEDOUT
element * .../BRANCH/LATEST
element * baseline -mkbranch(BRANCH)
element * /main/LATEST
当我创建一个新元素时,我知道它与规则/ main / LATEST一起使用。当我执行cleartool ls时,可以找到新元素,但是如何使用cleartool find命令找到新元素。
When I make a new element I know it goes along with the rule /main/LATEST. When I do a cleartool ls I can find the new element, but how can I find the new element with a cleartool find command.
此外,这还假定新元素已签入,并且分支中签出的所有现有元素都已签入。新元素还没有任何元素标签。
Also this is assuming the new element has been checked in and all existing elements that where checked out under the branch have been checked in. The new element does not yet have any labels.
我一直在尝试:
cleartool find -avobs -branch 'brtype(BRANCH)' -version 'version(.../main/LATEST)'
我相信这只会搜索分支,而无法以这种方式找到新的签入元素。
I believe this only searches the branch and have not been able to find new checked in elements this way.
推荐答案
当我创建一个新元素时,我知道它与规则/ main / LATEST一起使用。
When I make a new element I know it goes along with the rule /main/LATEST.
是的,这意味着它是在 / main
分支中创建的,而不是在 BRANCH
分支中创建的。
仅在以下情况下在 Branch
分支中创建:
Yes, meaning it is created in the /main
branch, not in the BRANCH
branch.
It would be created in the BRANCH
branch only if:
- 不是 一个新元素
- 上面有一个标签(与基线名称匹配)
- it was not a new element
- it had a label on it (matching the baseline name)
因此您的查找
查询无法根据您当前的配置规范找到新元素。
So your find
query cannot find a new element, based on your current config spec.
新元素会仅具有 / main / 1
而没有 / main / 2
版本:
A new element would only have a /main/1
and no /main/2
version:
cleartool find -type f -version "version(/main/1)&&!version(/main/2)" -print
注意:如果要在分支 BRANCH
,则您的配置规范将需要有另一个规则(如此处所示):
Note: if you wanted to add a new element on the branch BRANCH
, your config spec would need to have another rule (as seen here):
element * CHECKEDOUT
element * .../BRANCH/LATEST
element * baseline -mkbranch(BRANCH)
element * /main/0 -mkbranch(BRANCH) <=====
element * /main/LATEST
这篇关于使用mkelem时,新元素会出现在哪里?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!