I have a project with sources under the control of CVSNT.
I need a list of source file names and revisions belonging to a certain tag. For example:
the tag MYTAG is:
myproject/main.cpp 1.5.2.3
myproject/myclass.h 1.5.2.1
I know that with cvs log -rMYTAG > log.txt
I get in log.txt
all the information I need and then I can filter it to build my list, but, is there any utility which already do what I need?
Here's a Python script that does this:
Note that you either have to have a
CVSROOT
environment variable set or run this from inside a working copy checked out from the repository you want to query.Also, the file names displayed are based on the "RCS File" property of the
rlog
output, i.e. they still contain the repository prefix. If you want to filter that out you can specify a third argument, e.g. when yourCVSROOT
is something likesspi:server:/cvsrepo
then you would call this like:Hope this helps.
Note: If you need a script that lists the revisions currently in your working copy, see the edit history of this answer.