ClearCase: How do I know the parent branch of a branch?

谁都会走 提交于 2019-12-10 10:28:21

问题


Is that possible to get hierarchy of branches? I have to know the father of a given branch I have to know the children of a given branch

How do I get it by cleartool? I prefer not to be based on a view config-spec

Thank you!


回答1:


With base ClearCase, you cannot know the parent of a branch, because it can vary from file to file: a file can start branch 'B2' from '/main/LATEST', another can start the same branch from '/main/B1/LATEST'.

For ClearCase UCM, you can determine the parent of a branch by querying the ancestors of a Stream (since the branch is name after the stream):

cleartool lsstream -anc myStream@pvob

That is possible because branches are linked to Streams, which are organized following a strict hierarchy a Parent Stream / Children Streams.

Note that describing a stream (cleartool describe, using fmt_ccase) only gives you access to the children streams: hence the lsstream -ancestor, in order to display its parent.



来源:https://stackoverflow.com/questions/12144146/clearcase-how-do-i-know-the-parent-branch-of-a-branch

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!