You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Ryan Bloom <rb...@ntrnet.net> on 2000/03/14 01:49:42 UTC

remove dirs from CVS?

How do you remove empty directories from CVS?  I have tried cvs rm, but
the dirs are still created when I checkout the source.  Do I have to login
to the server and remove them from the cvs directory myself?

Ryan


_______________________________________________________________________________
Ryan Bloom                        	rbb@apache.org
406 29th St.
San Francisco, CA 94131
-------------------------------------------------------------------------------


Re: remove dirs from CVS?

Posted by Martin Pool <mb...@linuxcare.com.au>.
On Mon, Mar 13, 2000 at 10:12:33PM -0500, rbb@apache.org wrote:

> > Now, if you're talking about a directory that should have never
> > existed, then you're talking about revising history. That would
> > definitely involve mucking with the repository itself, and that's not
> > kosher.
> 
> Okay, my problem is that the directory should never have been there and I
> wanted to revise history.  Never mind.  :-(

In particular, deleting the directory if somebody has already made a
checkout that included it will greviously confuse their client.  (Hmm,
I wonder when we'll be able to work from a DAV server?)

-- 
Martin Pool, (null), Linuxcare, Inc.
+61 2 6262 8990
mbp@linuxcare.com, http://www.linuxcare.com/
Linuxcare. Support for the revolution.

Re: remove dirs from CVS?

Posted by Chuck Murcko <ch...@topsail.org>.
Manoj Kasichainula wrote:
> 
> On Mon, Mar 13, 2000 at 09:28:36PM -0500, Ryan Bloom wrote:
> >
> > I know that will keep me from getting them, but we really don't have
> > anything in those directories anymore, and I would prefer if we could just
> > get rid of them all together.  Are you telling me that once you add a
> > directory to the CVS repository, that directory stays there forever?
> 
> Well, naturally. If I want to be able to check out a version of the
> tree from back before the directory was deleted, I want to see that
> directory.
> 
> Now, if you're talking about a directory that should have never
> existed, then you're talking about revising history. That would
> definitely involve mucking with the repository itself, and that's not
> kosher.

Well, it sort of is, if there's agreement the thing *never* should have
been there (and I've only ever had someone check code into a repository
once that needed this) you can always do

cvs admin -o<range> files

and get rid of all the files that were ever in the directory,
permanently, and then remove the directory from the repository (making
sure no one has the thing checked out first). This is Real Severe, and
should be reserved only for the most evil things that got committed. You
are basically wiping all record that the files and directory ever
existed, even from the attic.

The canonical example is

cvs admin -o:R_1_02 .

which removes everything up to and including R_1_02 from the current
directory. It will also mess up the accounting (same numerical revision
number will be assigned) for any files which did not change between
R_1_02 and the next revision's tag, which is bad.

IMHO, it doesn't sound like this stuff is so bad that -P wouldn't do.
-- 
Chuck
Chuck Murcko
Here: chuck.murcko@trintech.com
There: chuck@topsail.org

Re: remove dirs from CVS?

Posted by rb...@apache.org.
> Well, naturally. If I want to be able to check out a version of the
> tree from back before the directory was deleted, I want to see that
> directory.
> 
> Now, if you're talking about a directory that should have never
> existed, then you're talking about revising history. That would
> definitely involve mucking with the repository itself, and that's not
> kosher.

Okay, my problem is that the directory should never have been there and I
wanted to revise history.  Never mind.  :-(

Ryan


_______________________________________________________________________________
Ryan Bloom                        	rbb@apache.org
406 29th St.
San Francisco, CA 94131
-------------------------------------------------------------------------------


Re: remove dirs from CVS?

Posted by Manoj Kasichainula <ma...@io.com>.
On Mon, Mar 13, 2000 at 09:28:36PM -0500, Ryan Bloom wrote:
> 
> I know that will keep me from getting them, but we really don't have
> anything in those directories anymore, and I would prefer if we could just
> get rid of them all together.  Are you telling me that once you add a
> directory to the CVS repository, that directory stays there forever?

Well, naturally. If I want to be able to check out a version of the
tree from back before the directory was deleted, I want to see that
directory.

Now, if you're talking about a directory that should have never
existed, then you're talking about revising history. That would
definitely involve mucking with the repository itself, and that's not
kosher.


Re: remove dirs from CVS?

Posted by Evan Klinger <ev...@sirius.com>.
rbb@apache.org wrote:
> 
> I know that will keep me from getting them, but we really don't have
> anything in those directories anymore, and I would prefer if we could just
> get rid of them all together.  Are you telling me that once you add a
> directory to the CVS repository, that directory stays there forever?
> 
> Ryan

Try cvs remove dir; cvs commit dir.
-- 

ev

----------------------------
Evan Klinger	evan@php.net
AIM		evan715

Re: remove dirs from CVS?

Posted by Ask Bjoern Hansen <as...@valueclick.com>.
On Mon, 13 Mar 2000 rbb@apache.org wrote:

> I know that will keep me from getting them, but we really don't have
> anything in those directories anymore, and I would prefer if we could just
> get rid of them all together.  Are you telling me that once you add a
> directory to the CVS repository, that directory stays there forever?

Just put 

update -P 

(or -dP)

in your .cvsrc and update's should prune empty directories.


 - ask

-- 
ask bjoern hansen - <http://www.netcetera.dk/~ask/>
more than 70M impressions per day, <http://valueclick.com>


Re: remove dirs from CVS?

Posted by Marc Slemko <ma...@znep.com>.
On Mon, 13 Mar 2000 rbb@apache.org wrote:

> 
> I know that will keep me from getting them, but we really don't have
> anything in those directories anymore, and I would prefer if we could just
> get rid of them all together.  Are you telling me that once you add a
> directory to the CVS repository, that directory stays there forever?

Yes.  CVS doesn't version directories themselves, so you can't just remove
one.  Even if there is nothing there anymore, the whole point is that there
used to be something there, so CVS has to be able to support the version
of things where there was something there.  Aside from not being
able to access old versions of files if you below it away, it also
causes client nasties if you just blow away directories and there are
checked out copies that still have the non-empty directory.

That is one reason I always use -P in updates or checkouts.


Re: remove dirs from CVS?

Posted by rb...@apache.org.
I know that will keep me from getting them, but we really don't have
anything in those directories anymore, and I would prefer if we could just
get rid of them all together.  Are you telling me that once you add a
directory to the CVS repository, that directory stays there forever?


Ryan 

On Mon, 13 Mar 2000, Dean Gaudet wrote:

> don't remove them from the server or you'll screw up anyone else that has
> them in their working copies.
> 
> cvs update -P
> 
> should prune empty directories from your working copy.
> 
> or you can checkout a new copy.
> 
> Dean
> 
> On Mon, 13 Mar 2000, Ryan Bloom wrote:
> 
> > 
> > How do you remove empty directories from CVS?  I have tried cvs rm, but
> > the dirs are still created when I checkout the source.  Do I have to login
> > to the server and remove them from the cvs directory myself?
> > 
> > Ryan
> > 
> > 
> > _______________________________________________________________________________
> > Ryan Bloom                        	rbb@apache.org
> > 406 29th St.
> > San Francisco, CA 94131
> > -------------------------------------------------------------------------------
> > 
> > 
> 
> 


_______________________________________________________________________________
Ryan Bloom                        	rbb@apache.org
406 29th St.
San Francisco, CA 94131
-------------------------------------------------------------------------------


Re: remove dirs from CVS?

Posted by Wilfredo Sanchez <ws...@apple.com>.
| I know that will keep me from getting them, but we really don't have 
| anything in those directories anymore, and I would prefer if we  
could just
| get rid of them all together.  Are you telling me that once you add a 
| directory to the CVS repository, that directory stays there forever? 

  Directories are not versioned, so they stay around forever, yes.   
~/.cvsrc is your friend:

wsanchez% cat ~/.cvsrc
checkout -P
update -P -d
diff -u -d -b -w
rdiff -u
cvs -q -z3


--
       Wilfredo Sanchez, wsanchez@apple.com
Apple Computer, Inc., Core Operating Systems / BSD
          Open Source Engineering Lead
   1 Infinite Loop, 302-4K, Cupertino, CA 95014


Re: remove dirs from CVS?

Posted by Dean Gaudet <dg...@arctic.org>.
don't remove them from the server or you'll screw up anyone else that has
them in their working copies.

cvs update -P

should prune empty directories from your working copy.

or you can checkout a new copy.

Dean

On Mon, 13 Mar 2000, Ryan Bloom wrote:

> 
> How do you remove empty directories from CVS?  I have tried cvs rm, but
> the dirs are still created when I checkout the source.  Do I have to login
> to the server and remove them from the cvs directory myself?
> 
> Ryan
> 
> 
> _______________________________________________________________________________
> Ryan Bloom                        	rbb@apache.org
> 406 29th St.
> San Francisco, CA 94131
> -------------------------------------------------------------------------------
> 
>