Determine the view association of a UCM Activity from the command line

How can I determine which view (if any) is linked to an ClearCase UCM Activity from the command line

Views that are linked to a UCM Activity can be determined using the cleartool describe or the cleartool lsactivity -long command.

1. Set into any view
2. Mount and cd into the PVOB
3. Run the command cleartool describe activity:

Example: Windows example but same output for UNIX and Linux.

M:\View\PVOB> cleartool describe activity:MyActivity
activity "MyActivity"
created 13-Nov-05.19:57:35 by user.group@host
owner: user
group: group
stream: My_Stream@\PVOB
current view: My_Dev_View
title: MyActivity
change set versions:
M:\My_Dev_View\Source_Comp\headers@@\main\My_Stream\1\hello_world.h\main\My_Stream\3
4. Run the cleartool lsactivity -long for the same output.

Example:

M:\View\PVOB> cleartool lsactivity -long MyActivity
activity "MyActivity"
13-Nov-05.19:57:35 by user.group@host
owner: user
group: group
stream: My_Stream@\PVOB
current view: My_Dev_View
title: MyActivity
change set versions:
M:\My_Dev_View\Source_Comp\headers@@\main\My_Stream\1\hello_world.h\main\My_Stream\3

5. Use the -fmt switch to format your describe or lsactivity output. Review the ClearCase Reference Guide on the topic of fmt_ccase (cleartool man fmt_ccase) for more information on formatting strings for command output.

Example:

M:\View\PVOB> cleartool describe -fmt "%[view]p" activity:MyActivity
My_Dev_View


Note: If there is no line that specifies the current view returned in the output above, this means the activity is not linked to a view.

Example:

M:\View\PVOB> cleartool lsactivity -long MyActivity2
activity "MyActivity2"
13-Nov-05.19:57:35 by user.group@host
owner: user
group: group
stream: My_Stream@\PVOB
title: MyActivity2

No comments:

Post a Comment