Go Back  IT Forums > Software > Configuration Management
User Name
Password
Reply
 
Thread Tools Search this Thread Display Modes

find command...
  #1
Old 09-15-2006, 01:56 AM
Guest
Guest


Guest's Info
Posts: n/a
Default find command...

Hi there,

I want to use the find command to tell me the names of the elements
which are on a specific branch and that have been branched from a
specific label.

If the label is called MY_LABEL and there's a branch called MY_BRANCH
then how can I find out all the elements which exist on the MY_BRANCH
but have been branched from the element which has the MY_LABEL label?

In this software system there's loads of branches and labels so I have
to be specific.

Any ideas?

Peter

Reply With Quote
find command...
  #2
Old 09-15-2006, 04:15 AM
Dirk Heinrichs
Junior Member


Dirk Heinrichs is offline
Dirk Heinrichs's Info
Join Date: Jul 2003
Posts: 28
Default find command...

peterwduncan@googlemail.com wrote:

I assume you're talking about Clearcase, right?
Quote:
I want to use the find command to tell me the names of the elements which are on a specific branch and that have been branched from a specific label.


First, elements are not on branches, they have branches.
Quote:
If the label is called MY_LABEL and there's a branch called MY_BRANCH then how can I find out all the elements which exist on the MY_BRANCH but have been branched from the element which has the MY_LABEL label?


You can't do this directly, you'd need to write a little script which does
something like the following:

1) use cleartool find -bra to find all instances of your branch.
2) use cleartool des(cribe) to find out the version where it branched from
3) use cleartool des again, this time on the version found in step 2) to
find out wether it has the label in question attached.

Hmm, using "cleartool find ... -exec 'cleartool des ...'" you can combine 1)
and 2).

HTH...

Dirk
--
Dirk Heinrichs | Tel: +49 (0)162 234 3408
Configuration Manager | Fax: +49 (0)211 47068 111
Capgemini Deutschland | Mail: dirk.heinrichs@capgemini.com
Hambornerstraße 55 | Web: http://www.capgemini.com
D-40472 Düsseldorf | ICQ#: 110037733
GPG Public Key C2E467BB | Keyserver: www.keyserver.net
Reply With Quote
find command...
  #3
Old 09-15-2006, 04:20 AM
Guest
Guest


Guest's Info
Posts: n/a
Default find command...

Hi Dirk,

Thanks for the direction, I am indeed using ClearCase.

I've tried combinations of the Clearcase "find" but didn't know if the
result was possible from one command, you have clarified the situation
when you say it isn't possible.
I'll try to create a script now.

Thanks,
Peter

Dirk Heinrichs wrote:
Quote:
peterwduncan@googlemail.com wrote: I assume you're talking about Clearcase, right?
Quote:
I want to use the find command to tell me the names of the elements which are on a specific branch and that have been branched from a specific label.
First, elements are not on branches, they have branches.
Quote:
If the label is called MY_LABEL and there's a branch called MY_BRANCH then how can I find out all the elements which exist on the MY_BRANCH but have been branched from the element which has the MY_LABEL label?
You can't do this directly, you'd need to write a little script which does something like the following: 1) use cleartool find -bra to find all instances of your branch. 2) use cleartool des(cribe) to find out the version where it branched from 3) use cleartool des again, this time on the version found in step 2) to find out wether it has the label in question attached. Hmm, using "cleartool find ... -exec 'cleartool des ...'" you can combine1) and 2). HTH... Dirk -- Dirk Heinrichs | Tel: +49 (0)162 234 3408 Configuration Manager | Fax: +49 (0)211 47068 111 Capgemini Deutschland | Mail: dirk.heinrichs@capgemini.com Hambornerstraße 55 | Web: http://www.capgemini.com D-40472 Düsseldorf | ICQ#: 110037733 GPG Public Key C2E467BB | Keyserver: www.keyserver.net


Reply With Quote
find command...
  #4
Old 09-15-2006, 04:32 AM
Dirk Heinrichs
Junior Member


Dirk Heinrichs is offline
Dirk Heinrichs's Info
Join Date: Jul 2003
Posts: 28
Default find command...

peterwduncan@googlemail.com wrote:
Quote:
I'll try to create a script now.


As a starting point, try (on Unix):

cleartool find -avobs -bra 'brtype(mybranch)' -exec 'cleartool
des -fmt "%En@@%PSn\n" ${CLEARCASE_XPN}/0'

This should give you all the predecessor versions of .../mybranch/0

Bye...

Dirk
--
Dirk Heinrichs | Tel: +49 (0)162 234 3408
Configuration Manager | Fax: +49 (0)211 47068 111
Capgemini Deutschland | Mail: dirk.heinrichs@capgemini.com
Hambornerstraße 55 | Web: http://www.capgemini.com
D-40472 Düsseldorf | ICQ#: 110037733
GPG Public Key C2E467BB | Keyserver: www.keyserver.net
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump



Powered by: vBulletin Version 3.0.7
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Style Design by vBStyles.com


Top Contact Us - IT Forums - Archive - MyLounge Top
MyLounge.com Site Map
Forum: Cars, Cell Phone, Database, Games, Home Improvement, IT, Music, School, Sports, Web Design, Web Server, Weight Loss

The MyLounge.com forum is intended for informational use only and should not be relied upon and is not a substitute for any advice. The information contained on MyLounge.com are opinions and suggestions of members and is not a representation of the opinions of MyLounge.com. MyLounge.com does not warrant or vouch for the accuracy, completeness or usefulness of any postings or the qualifications of any person responding. Please consult a expert or seek the services of an attorney in your area for more accuracy on your specific situation. Please note that our forums also serve as mirrors to Usenet newsgroups. Many posts you see on our forums are made by newsgroup users who may not be members of MyLounge.com Term of Service