问题
I'm currently writing a script that has to check the recommended baseline of the Integration stream, so the only parameters that I know is the stream name, I'm wondering if there is a way to do that using cleartool on linux (bash script).
Here is my Vob:
And this is the Stream:
回答1:
You can use the fmt_ccase option %[rec_bls]CXp
:
On Windows:
cleartool descr -fmt "%[rec_bls]CXp" stream:streamName@\aPVob
On Unix:
cleartool descr -fmt "%[rec_bls]CXp" stream:streamName@/vobs/aPVob
You can see that command used in "How to describe recommend baseline with pipeline".
I have a few components in this stream, how should I mention which one I want?
Recommended baselines are associated to an UCM project or UCM stream, and include one or several components.
So you need to list those baselines first, then, for each one, check if your component(s) is included.
For each baseline found, you can list its component, as shown in "how to find root[folder] for each component using cleartool?"
cleartool lsbl -fmt "%[component]p" baseline:baselineName@\aPVob
(as usual, replace 'streamName
', 'baselineName
' or 'aPVob
' with the appropriate names in your case)
来源:https://stackoverflow.com/questions/25426956/how-can-i-list-the-recommended-base-line-in-clearcase