[Top][All Lists]

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

Re: address@hidden: Re: rename in cvs]

From: Sam Steingold
Subject: Re: address@hidden: Re: rename in cvs]
Date: 10 Oct 2001 17:31:23 -0400
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.107

> * In message <address@hidden>
> * On the subject of "Re: address@hidden: Re: rename in cvs]"
> * Sent on Wed, 10 Oct 2001 15:06:14 -0400 (EDT)
> * Honorable address@hidden (Greg A. Woods) writes:
> [ On Wednesday, October 10, 2001 at 10:52:04 (-0700), Paul Sander wrote: ]
> > Subject: Re: address@hidden: Re: rename in cvs]
> >
> > Generally speaking, renaming stuff in CVS is royal pain.  You always lose
> > something.  It's up to you to decide what you're willing to give up.
> You never loose anything if you do it right.
> (and assuming some bugs are fixed in some ancillary sub-commands)

if you rename FOO to BAR "the right way", i.e.,

$ mv FOO BAR
$ cvs rm FOO
$ cvs add BAR
$ cvs ci BAR

then you lose in many ways:

 * 'cvs log BAR' does not list changes in file FOO

 * there is no way to compare BAR 1.123 with FOO 1.321
   [yeah, they are separated by over a hundred revisions, so what?
    there are still situations when this makes sense.]

 -->  etc - CVS does not know that FOO is the old name for BAR.

 * also, this operation cannot be undone gracefully: when I do the above
   renaming backwards, CVS moves BAR,v into the attic and there is no
   way to get the revisions of BAR into the FOO,v file
   (or is there - how do I concat two *,v files?!)

This is why I usually rename the *,v files, edit them manually to
replace file names in $Id$ and also edit history.

The problem is that I do not always have shell access - then I am stuck.

Ideally I want to be able to say
$ cvs rename -r 2.0 FOO BAR
so that BAR 2.0 is the same as the current FOO.
then BAR 1.123 will be the same as FOO 1.123.
CVS would know that FOO and BAR are the same logical file.
        $ cvs co -r 1.123 BAR
        $ cvs co -r 1.123 FOO
would create a file named FOO while
        $ cvs co -r 2.0 BAR
        $ cvs co -r 2.0 FOO
would create a file named BAR

Sam Steingold (
Support Israel's right to defend herself! <>
Read what the Arab leaders say to their people on <>
Only adults have difficulty with childproof caps.

reply via email to

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