[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: revision/version numbers

From: Todd Denniston
Subject: Re: revision/version numbers
Date: Mon, 03 Nov 2003 10:14:12 -0500

"Jim.Hyslop" wrote:
> Katherine King [mailto:address@hidden wrote:
> Now, having said all that, if they want to see if something's changed, they
> can use the diff command:
> cvs diff -rPREVIOUS_TAG -rCURRENT_TAG filename
> If diff says nothing, then the file has not changed.
> To get exactly what you have asked for (which is really not that useful,
> given what the goal of your testers seems to be) you can issue these
> commands:
>   echo ^RCS file:>filerev
>   echo ^revision >>filerev
>   cvs log -rCURRENT_TAG | grep -f filerev
> The output will look something like this:
> cvs server: Logging .

 cvs log -rCURRENT_TAG 2>&1|grep -e "^revision" -e "^RCS file:" 

I think the above may give you some false positives, the files in the Attic
(dead & don't have the tag) lists all revs in the file.

cvs log -t |grep -e "CURRENT_TAG" -e "^RCS file:"
shows all files and whether they have the tag.

cvs log -t |grep -e "CURRENT_TAG" -e "^RCS file:"|grep -B1 "CURRENT_TAG"
shows just the files that have the tag. (I think)

Of course with any of the methods you may have to do some awk/perl/'text
editor' to reduce the data for non programmers so the _repository directory_
and ',v' are gone.

BTW What Paul Sander indicated "Labels are not immutable; they can be moved
around." is true, though hopefully if it is an important tag the person who did
it will be beaten with an _appropriate_ clue bat, then you can recover with the
information recorded from one of the methods above. I guess I have been lucky
and no one other than me (CM person) has messed about with tags, I may have to
start keeping a file for the above on releases in the future.

Todd Denniston
Crane Division, Naval Surface Warfare Center (NSWC Crane) 
Harnessing the Power of Technology for the Warfighter

reply via email to

[Prev in Thread] Current Thread [Next in Thread]