[Top][All Lists]

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

Re: CVS diff and unknown files.

From: Mark D. Baushke
Subject: Re: CVS diff and unknown files.
Date: Wed, 02 Feb 2005 15:33:28 -0800

Hash: SHA1

Greg A. Woods <address@hidden> writes:

> Yes -- we are in almost full agreement, but it cannot use '-n'.  (no
> commitinfo scripts are run with '-n' and I don't think they should be or
> ever need to be)

I believe this statement does not reflect the current state of cvs. 
(I may have missed something where you wanted to change the existing
behavior and are using that as the basis for your statement.)

The commitinfo triggers are run even when the -n switch is used. Try it
for yourself with a stock version of cvs 1.11.x or cvs 1.12.x.

  cvs -d `uname -n`:/tmp/my-repos init
  cvs -d `uname -n`:/tmp/my-repos co CVSROOT
  echo 'DEFAULT echo commitinfo trigger running:' >> commitinfo
  cvs commit -m new-default commitinfo
  touch foo
  cvs add foo
  cvs -n ci -madd-foo foo

You should get the output:

  commitinfo trigger running: /tmp/my-repos/CVSROOT foo

In addition, the current 'cvs' requires that you actually contact the
server to cause a new directory to be added. If I just do a simulated
call that modifies a 'mkdir newdir && cvs add newdir' to these steps:

  mkdir newdir newdir/CVS
  echo 'D/newdir////' >> CVS/Entries
  cp CVS/Root newdir/CVS/Root
  echo `cat CVS/Repository`/newdir > newdir/CVS/Repository
  touch newdir/CVS/Entries

then subsequent 'cvs update' operations will have problems such as this:

  % cvs up
  cvs update: Updating .
  A foo
  cvs update: Updating newdir
  cvs update: cannot open directory /tmp/my-repos/CVSROOT/newdir: No such file 
or directory
  cvs update: skipping directory newdir

which will require that 'newdir' be created via a 'cvs add' conversation
with the server eventually.

As a reminder, no matter how much folks believe things should be different:
  - currently the 'cvs add' command talks to the server

  - on the occasion of a 'directory' being added, the directory is
    created in the repository if a lock may be created and valid
    permissions exist to create it. Next, the loginfo trigger is run.

Any changes to cvs to alter the behavior of 'cvs add' should allow for
new clients to talk to old servers and for old clients to talk to new
servers in addition to new clients talking with new servers.

        -- Mark
Version: GnuPG v1.2.3 (FreeBSD)


reply via email to

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