Greg Woods, CVS guru, wrote:
[...]
> > If somebody is interested, I can try to make a version of my patch
> that
> > makes HEAD work as it does for "cvs diff" in all the other cases. I
> don't
> > think it's very hard. (Hardest part will probably be fixing
> sanity.sh...)
>
> I'd be interested but don't bother to do it just on my account alone --
> I'll be able to to the same when I get some free time too....
>
[smc] Is there anything lost by doing this, that is.
is there anything that can be done with the current
implementation of HEAD that, were it changed
in this way, could not be done in some other way?
> > > You don't really want it to be a CVS
> > > magic branch tag but rather just the real RCS trunk branch identifier.
> >
> > [smc] Oh...I thought you meant you had some way to make a name for
> > the trunk as I described above. Tagging the trunk, while useful,
> isn't as
> > ideal, to my mind, as a real branch-tag name that means the trunk.
>
> But tagging the trunk with its RCS branch identifier (i.e. "1") is
> indeed exactly what you need to do if you want to create a symbolic name
> to refer to the trunk. You most definitely do not want to try to create
> a CVS magic branch tag for the trunk -- that will not work right.
[smc] Yes, I know it won't work right... But a
regular tag won't do what I want either. So, if you
create a TRUNK tag (just a regular tag that points
to a bunch of revisions that happen to be at the tip
of the trunk _right now_) then I can't do this:
cvs co -r TRUNK everything
(change some files)
cvs commit -m changed some files on the trunk'
_That's_ what I want, a tag which behaves like a
branch tag, but means the trunk.
> Also, I have confirmed that using "1" will work just fine even if
> someone has rolled the release number up to 2.x (and 3.x and so on).
>
[smc] ok cool.
Hmm. I jsut tried the following:
cvs co -r 1 everything
cd everything
(edit some files)
cvs commit -m 'changed some stuff'
And, oh miracle! it worked! I really didn't expect that,
since ordinarily, giving revision numbers like that is
definitely not akin to giving a branch tag...
But hang on a sec. I just tried this:
echo aaaa >> somefile
cvs commit -r 2.0 -m whatever somefile
cd someplace else
cvs co -r 1 everything
cvs status somefile
I got revision 1.3 of somefile, not 2.0...
So, for "cvs co", -r 1 doesn't appear to work in such
a way that it may be used as a kind of branch tag for the trunk.
(I won't say that it works wrong, 'cause I don't know how the heck
it's supposed to work...)
Hmm, I tried this with cvs 1.10.7...not sure about 1.10.8, but I
doubt there
were changes in this area...
-- steve