[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: The hated $Log$ keyword
From: |
Eric Siegerman |
Subject: |
Re: The hated $Log$ keyword |
Date: |
Wed, 11 Jul 2001 15:40:04 -0400 |
User-agent: |
Mutt/1.2.5i |
On Mon, Jul 09, 2001 at 04:12:30AM -0400, Greg A. Woods wrote:
> [ On Monday, July 9, 2001 at 00:01:01 (-0400), Eric Siegerman wrote: ]
> Well, with CVS the meaning of "frozen" file is quite a bit different.
>
> In the most basic sense what I'm saying is that "-kv" should be the
> default for "cvs export".
Ah, now I get it. Agreed -- except that it shouldn't override
"-kb" of course.
> This option is useful for
> software distribution. A revision that is sent to
> several sites should be checked in with the -k
> option at these sites to preserve the original num-
> ber, date, author, and state.
>
> In practice I don't think this scheme has ever worked very well unless
> all sites in question had an agreed upon branching plan
Or even if there was only one site. I tried this with a couple
of open-source things I downloaded, and quickly ran into the
problem of new files going in at 1.1 instead of 5.1 or whatever.
Same problem that makes "cvs ci -r2" not very useful.
> Of course in both CVS and RCS the ultimate problem with having the
> keyword markers in the frozen files is that subsequent checkins/imports
> to a new repository (without '-k') will clobber the old value. This is
> why '-kv' should be the default for "cvs export", and why large projects
> using RCS (or those using CVS who haven't learned to use "cvs export")
> have always invented their own project-specific keyword (eg. $NetBSD,
> $Xconsortium, $XFree86, etc.)
One way to solve this would be to make the vendor branch a
special case. When checking out a file (whether with "co" or
"update"), if you're getting it from the vendor branch, override
the file's keyword-substitution setting and just do "-ko".
So when I import the CVS sources (for e.g.) and do a fresh
checkout, my sandbox will contain the original $Id$ values that
were in the distribution. When I modify and commit some file,
*only* that file will now contain $Id$ values of the revision
from my repo.
(Ideally -kb should trump this wrinkle, as it should all other
check-out-time -k settings, but that's another story.)
--
| | /\
|-_|/ > Eric Siegerman, Toronto, Ont. address@hidden
| | /
With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea.
- RFC 1925 (quoting an unnamed source)