3

I need to retrieve a list of all the files that have been checked-in across baselines along with the owner name. I tried using the cleartool lsact command :

However, this command fetches just for one task and is a bit cumbersome to use. Is there a command which will retrieve all the tasks if I specify two baselines?

Thanks

Sai
  • 376
  • 7
  • 18

1 Answers1

2

A command like:

 cleartool diffbl -act bl1@\apvob bl2@\apvob

will give you the list of activities which have new versions between baselines bl1 and bl2.

However, to get the list of files (ie elements, as in files or directories, and not versions as in all the updated versions even for a same file), the best way is to:

  • ensure those baselines are "full" baseline: promote them to full if needed:
    cleartool chbl -full bl1@\apvob
    cleartool chbl -full bl2@\apvob

(if they were already full, this command won't do anything)

  • list all elements which have the bl1 and bl2 labels on different versions:
cleartool find -all -element '{lbtype_sub(REL1) && lbtype_sub(REL2)}' ^ 
  -version '{(lbtype(REL1) && ! lbtype(REL2)) || ^
  (lbtype(REL2) && !lbtype(REL1))}' -print 

See "Find changes between labels".
Note that this last question also mentions the "report builder packaged with ClearCase, which is interesting if you are after a solution involving a GUI and not a CLI (command line):

report builder

Again, if those baselines are full, you can use it to list (under Elements/Labels) either "Elements Changed Between Two Labels" or "Versions Changed Between Two Labels" depending on which you need.

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • Hi .. I tried this command but it is giving me a list of activities. What I am looking for is a list of all the files that have been modified for each activitiy across all activities. – Sai May 10 '12 at 05:32
  • @Sai I was editing my answer: see the edited answer, or as another alternative http://stackoverflow.com/questions/9256649/how-to-get-the-list-of-the-checkin-files-between-two-clearcase-ucm-lables-in-uni – VonC May 10 '12 at 05:35
  • @Sai just added the "report builder" option as well – VonC May 10 '12 at 05:40
  • Hi... thanks a lot for your help. Actually, I am very new to using clear case commands and I am running on Windows platform. I went through the links that you have mentioned, but all of them seem to throw some errors!! – Sai May 10 '12 at 06:06
  • @Sai: don't hesitate to add in those comments the commands you are typing and the error message you get: I will fix those commands – VonC May 10 '12 at 06:50
  • Hi.. tried using this command cleartool diffbl -activities -elements baseline:[first_Baseline]@\VOB baseline:[second_Baseline]@\VOB. This command fetches a list of activities and files, however it contains some deliver baseline info as well. I am not sure it correctly fetches the required details. Also, it does not give me the owner name. Can you please help? – Sai May 10 '12 at 06:54
  • 1
    @Sai: the diffbl -act if for listing activities, which isn't what you want. For the proper syntax, see http://publib.boulder.ibm.com/infocenter/cchelp/v7r0m0/topic/com.ibm.rational.clearcase.cc_ref.doc/topics/ct_diffbl.htm – VonC May 10 '12 at 07:53
  • @Sai: I would advise the `chbl` and `find` approach. – VonC May 10 '12 at 07:53