Search code examples
linuxunixclearcase

How to get ClearCase stream name by a given view path?


Let's say I'm inside a view on Linux (snapshot or dynamic). I forgot what's the stream that that view belongs to.

How do I get it? Should I extract if from the config-spec (after -mkbranch) or is there any better way?


Solution

  • You can take advantage of the -cview option of the lsstream command:

    cleartool lsstream -cview
    

    With fmt_ccase:

    cleartool lsstream -fmt "%n" -cview
    

    I like to see where this stream is located within a project, so I usually do a:

    cleartool lsstream -cview -anc