[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CVS tries to update files it should leave alone
From: |
Eric Siegerman |
Subject: |
CVS tries to update files it should leave alone |
Date: |
Tue, 29 Apr 2003 18:43:02 -0400 |
User-agent: |
Mutt/1.2.5i |
Observed with development CVS as of 29-Apr-2003, and also with
random client and server mixes of 1.11.5, 1.11.5-FreeBSD (i.e.
with their patches) and 1.11.2.1.
Under certain circumstances, CVS tries to update files it should
leave alone. If, using CVS client/server, I type:
cvs update subdir/
(with the trailing slash, as provided by my shell's file
completion), CVS will say:
cvs update: move away ./<file>; it is in the way
C <file>
about each file in the current directory *only* (i.e. not
recursively).
I've included a log demonstrating the bug. Most of it is setup,
and can be lightly skimmed. The interesting parts are at the
end, commented with "###".
More observations (most are not shown in the log):
- It only happens client/server; locally everything's fine
- "cvs -n update subdir/" simply reports "U <file>" for files
in the current directory -- no conflict -- but it does so
*whether or not* the file really needs updating
- if a file in the current directory has been locally modified,
"cvs -n update subdir/" *still* reports "U <file>" (or,
without the "-n", a conflict), when it should be reporting
"M <file>"
- "cvs commit" seems *not* to have this problem (I haven't
tried other commands)
- None of this weirdness applies to files in the "subdir"
named on the command line. Everything goes as expected
in there.
- Other subdirectories (at the same level as subdir) are
skipped, as they should be
Hypothesis: Somehow, the trailing slash tricks CVS into
operating on the current directory as well as on the named
subdirectory, but it hasn't read ./CVS/Entries, so it doesn't
think any of the files are supposed to exist.
I haven't tried any of this with subdirectories more than one
deep. "cvs update sub1/sub2/" would be interesting...
===================== Begin log ======================
#
# Here's the beginning state. The content of files foo and
# sub/bar seems irrelevent (bug.log can be ignored).
#
$ ls -lR
.:
total 4
-rw-rw-r-- 1 erics erics 0 Apr 29 17:41 bug.log
drwxrwxr-x 3 erics erics 4096 Apr 29 17:29 tiny-import
./tiny-import:
total 8
-rw-rw-r-- 1 erics erics 4 Apr 29 17:29 foo
drwxrwxr-x 2 erics erics 4096 Apr 29 17:29 sub
./tiny-import/sub:
total 4
-rw-rw-r-- 1 erics erics 4 Apr 29 17:29 bar
#
# Make sure client/server uses the test binary, not the installed
# one.
#
$ CVS_SERVER=`which cvs` export CVS_SERVER
$ echo $CVS_SERVER
/home/erics/p/cvs/ccvs/src/cvs
#
# Make a repo, and import ./tiny-import as module "tiny"
#
$ cvs -d `pwd`/Repos init
$ cd tiny-import
$ cvs -d `pwd`/../Repos import -m imported tiny vendor version-1
N tiny/foo
cvs import: Importing /home/erics/p/cvs/bug2/tiny-import/../Repos/tiny/sub
N tiny/sub/bar
No conflicts created by this import
#
# Check out two sandboxes of "tiny" -- local and client/server.
#
$ cd ..
$ cvs -d `pwd`/Repos co -d tiny-local tiny
cvs checkout: Updating tiny-local
U tiny-local/foo
cvs checkout: Updating tiny-local/sub
U tiny-local/sub/bar
$ cvs -d :fork:`pwd`/Repos co -d tiny-fork tiny
cvs server: Updating tiny-fork
U tiny-fork/foo
cvs server: Updating tiny-fork/sub
U tiny-fork/sub/bar
#
# Verify that both client and server are the test CVS (now that
# we have a c/s sandbox in which to do so)
#
$ cd tiny-fork
$ cvs version
Client: Concurrent Versions System (CVS) 1.12.0.1 (client/server)
Server: Concurrent Versions System (CVS) 1.12.0.1 (client/server)
###
### In the local sandbox, these three variants of "cvs update"
### are all ok
###
$ cd tiny-local
$ cvs -q update
$ cvs -q update sub
$ cvs -q update sub/
###
### In the client/server sandbox, the first two variants are ok,
### but the third declares a conflict about a file that:
### - isn't in conflict, and
### - CVS wasn't supposed to be looking at in the first place
###
#
$ cd ../tiny-fork
$ cvs -q update
$ cvs -q update sub
$ cvs -q update sub/
cvs update: move away ./foo; it is in the way
C foo
$
===================== End log ======================
--
| | /\
|-_|/ > Eric Siegerman, Toronto, Ont. erics@telepres.com
| | /
My Wine works. However it crashes about half the time on startup.
Apparently their simulation of windoze API is getting too accurate. :)
- Kyle Sallee
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- CVS tries to update files it should leave alone,
Eric Siegerman <=