Jump to content

cli cm examples needed


u2468

Recommended Posts

Please, can you help me with the following:

/main: [0]-->[1]-->[2]--[3]-->[5]-->[8]
                         |
                         |
                         +---/main/branch1: [4]-->[6]-->[7]

1) Using command line cm, I want to be able to specify a branch name only, and find the last changeset number in the branch.  (ex. 7 above)

 

2) Using command line cm, I want to be able to specify a branch name only, and find the first changeset number in the branch.  (ex. 4 above)

 

3) Using command line cm, I want to be able to specify a branch name only and find the 'root' changeset number of the branch. (ex. 3 above.)

 

You can assume that I'm already in the workspace directory. 

 

Thanks very much!

Link to comment
Share on other sites

Hi!

 

1) cm find branch where name='main' --format={changeset} --nototal

 

2) cm find changeset where branch='main' --format={changesetid} --nototal

(and take the first one)

 

3) cm find changeset where branch='main/per' --format="{changesetid}>{parent}" --nototal

(and take the first result)

 

More info here: https://www.plasticscm.com/documentation/cmfind/plastic-scm-version-control-query-system-guide.shtml#Chapter3:Changesets

Link to comment
Share on other sites

  • 7 months later...

Hi,

 

The find according to branch name does not work. 

 

example:

$ cm find branch "where name='CR1234'"
18220    18/01/2013 11:47:21 /main/CR1234 John _TEST_REPO T
18724    26/11/2013 10:46:03 /test11/CR1234 John _TEST_REPO T
but when I try this query, I get  no match:
$ cm find branch "where name='test11/CR1234'"


Total: 0

I need to find a specific branch name in an environment where I have multi sub-branches with identical name.

 
Any idea?
I'm using PlasticSCM release 5.4.16.688.
 
Ofir.
 
Link to comment
Share on other sites

  • 4 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...