Discussion:
Identifying base version-no of all files in a branch
(too old to reply)
Bulgrien, Kevin
2012-08-02 13:26:41 UTC
Permalink
Is there a CVS command that will provide me with version
no(base version) of all the files in a branch.
What I mean by 'base version' here is...the version no of
all the files in a branch..when the branch was first created.
I want to create a plugin in Eclipse...through which I can
retrieved the base version no of all the files in a branch.
Thanks every one in advance
The only simple way of doing this that I know about is to lay a
non-branch tag down at the time the branch is created as a
consistently applied best practice.

The list archives contain threads that discuss a number of ideas
about how one might to analytically determine this information.
Some of these threads deal with trying to find the time/date
that a branch was created, but that is very much the same kind
of issue.

This message and/or attachments may include information subject to GD Corporate Policy 07-105 and is intended to be accessed only by authorized personnel of General Dynamics and approved service providers. Use, storage and transmission are governed by General Dynamics and its policies. Contractual restrictions apply to third parties. Recipients should refer to the policies or contract to determine proper handling. Unauthorized review, use, disclosure or distribution is prohibited. If you are not an intended recipient, please contact the sender and destroy all copies of the original message.
Larry Jones
2012-08-02 20:09:15 UTC
Permalink
Is there a CVS command that will provide me with version no(base version) of all the files in a branch.
No, I'm afraid not. The best you could do would be to parse the output
of ``status -v'' or ``log'' to get the definition of the branch tag in
each file and then infer the base version from it.
--
Larry Jones

These findings suggest a logical course of action. -- Calvin
Larry Jones
2012-08-02 20:23:18 UTC
Permalink
Post by Bulgrien, Kevin
The list archives contain threads that discuss a number of ideas
about how one might to analytically determine this information.
Some of these threads deal with trying to find the time/date
that a branch was created, but that is very much the same kind
of issue.
No, it's not. CVS knows, absolutely and for sure, what the base
revision of the branch is in each file -- branches wouldn't work if it
didn't. But it has no concept of *when* the branch was created; it
could be different for each and every file.
--
Larry Jones

I don't need to do a better job. I need better P.R. on the job I DO.
-- Calvin
Arthur Barrett
2012-08-03 00:50:41 UTC
Permalink
Kevin/Larry/etc,

It's EASY to obtain the base revision number - it's hardcoded in the
branch number.

Eg:
CVSNT_BRANCH_2_8_01_3761: 1.106.2.210.6.99.0.2

Base revision of CVSNT_BRANCH_2_8_01_3761 is 1.106.2.210.6.99

Yes it's different for every file (but that's stating the obvious, since
revision numbers are unique per file) - but it's not in any way
difficult to obtain. There isn't a "comand line" to checkout the 'base
revision', but since mthread/rjkumr is writing an Eclipse extension, a
list of version numbers is all that is needed isn't it? Once the list
of version numbers is obtained, retrieving the base revisions is easy in
a program/script...
Hi,
Is there a CVS command that will provide me with version
no(base version) of all the files in a branch.
What I mean by 'base version' here is...the version no of
all the files in a branch..when the branch was first created.
I want to create a plugin in Eclipse...through which I can
retrieved the base version no of all the files in a branch.
Thanks every one in advance
Better to replace 'all' with 'each' in your question - I think that
distiction is the cause of the confusion.

I've added an enhancement request for this to command line CVSNT:
http://customer.march-hare.com/webtools/bugzilla/ttshow_bug.cgi?tt=1&id=
6537

eg:
cvs co -r :CVSNT_2_0_x
cvs diff -r :CVSNT_2_0_x


Regards,



Arthur Barrett
CVS Suite (CVSNT)
Product Manager
-----Original Message-----
org] On Behalf Of Larry Jones
Sent: Friday, 3 August 2012 6:23 AM
To: Bulgrien, Kevin
Subject: Re: Identifying base version-no of all files in a branch
Post by Bulgrien, Kevin
The list archives contain threads that discuss a number of ideas
about how one might to analytically determine this information.
Some of these threads deal with trying to find the time/date
that a branch was created, but that is very much the same kind
of issue.
No, it's not. CVS knows, absolutely and for sure, what the base
revision of the branch is in each file -- branches wouldn't work if it
didn't. But it has no concept of *when* the branch was created; it
could be different for each and every file.
--
Larry Jones
I don't need to do a better job. I need better P.R. on the job I DO.
-- Calvin
Larry Jones
2012-08-03 20:28:52 UTC
Permalink
Post by Arthur Barrett
It's EASY to obtain the base revision number - it's hardcoded in the
branch number.
Exactly (which is why it's nothing like trying to intuit the date/time
the branch was created). For generality, you need to support normal RCS
branches in addition to CVS magic branches, but that's just a small
detail.
Post by Arthur Barrett
but since mthread/rjkumr is writing an Eclipse extension, a
list of version numbers is all that is needed isn't it?
Correct, and that's what there's no easy way to do, you have to parse
the output from ``status -v'' or ``log'', and that's not trivial.
--
Larry Jones

I like Mom to be impressed when I fulfill the least of my obligations.
-- Calvin
Arthur Barrett
2012-08-05 21:59:18 UTC
Permalink
Larry/etc,
Post by Larry Jones
Post by Arthur Barrett
but since mthread/rjkumr is writing an Eclipse extension, a
list of version numbers is all that is needed isn't it?
Correct, and that's what there's no easy way to do, you have to parse
the output from ``status -v'' or ``log'', and that's not trivial.
I've not looked at the Eclipse code closely, but I think the log output
is already parsed, if someone is writing an eclipse extension they're
leveraging all that existing code/structures/classes.

Regards,


Arthur

Loading...