Search code examples
clearcase

ClearCase: How to get when a LABEL was created?


I would like to get the date when a label was created.

The command below does list the labels, but all of them. I would like to only get the date associated with a specific label.

cleartool lstype -kind lbtype -invob $(cygpath -wa $VIEWDIR)

And if possible without extensive use of grep or sed to extract the information.


Solution

  • For a given lbtype, you can use the cleartool describe command:

    cleartool descr lbtype:MYLABEL@/vob/myvob
    

    Combined with fmt_ccase, you can limit to only the date

    cleartool descr  -fmt "%d" lbtype:MYLABEL@/vob/myvob
    

    This gives the creation date of the label type (not when a label was set to a version)