[cvsnt] Re: edit/commit/unedit problem - cvs edit -z (was: edit/commit/unedit problem)

Gerhard Fiedler lists at connectionbrazil.com
Mon Jun 7 01:08:36 BST 2004


Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.


This issue is splitting up into three different ones, so I split my
answers, too. This answer is about "cvs commit" after "cvs edit -z", which
seems to be broken in the client.


On 6/5/04 20:23:06, Tony Hoyle wrote:
> Gerhard Fiedler wrote:
>> - I cvs edit a file (but don't modify it).
>> - I cvs update it and the file gets updated by cvs and marked read-only.
>> - I then cvs unedit the file and cvs tells me that the file has been
>> modified and asks me whether I want to revert the changes.
...
>> Well, this is not what I experience. It happens also after a commit: if I
>> do a cvs unedit after a commit, I get the question whether I want to revert
>> the changes. If I say no, it just keeps asking me forever (or until I do
>> another edit). If I say yes, it reverts the just committed file to a
>> previous revision, and I have to cvs update it to get the one I just
>> committed.
> 
> It won't unedit as there's no file to unedit to after a commit (unless 
> you're trying to unedit on the other sandbox of course).  

This is not correct. It seems there is something broken with the -z flag of
the cvs edit command. Please see the two command line logs attached at the
end of the message. When I cvs edit with the -z flag, the .gz file in the
CVS/Base directory is still there after a commit.

When I work from the command line, I never use this flag. I don't think
that WinCvs uses it. But TortoiseCVS uses it, and that's where I started to
see the problems. After a bit of searching around, I finally could isolate
this.

> I think the 
> code should also be processing the Baserev file to do a full unedit but 
> as it's never actually done that and it seems to work I'll leave it 
> alone for now.

I don't really know what you are talking about -- I have seen the Baserev
directories every now and then, but I don't know when and how they get
used.


Now here are the command logs. 

First I run a simple edit/commit/unedit sequence without the -z flag. It
behaves as one expects. 

The second sequence shows the same, but with the -z flag in the edit
command. As you can see, the file has been committed ok, it is not
considered "edited" by the server, but the Base copy is still there -- and
the client wants to revert to the revision before the commit in the unedit
command.


-----------------------------------------------------------
e:\projects\zother\test>cvs version
Client: Concurrent Versions System (CVSNT) 2.0.41a (client/server)
Server: Concurrent Versions System (CVSNT) 2.0.34 (client/server)

--- sequence 1: edit without -z ---------------------------
e:\projects\zother\test>cvs edit -c test.txt

e:\projects\zother\test>test.txt [modified and saved file]

e:\projects\zother\test>cvs -r commit -m "test" test.txt
Checking in test.txt;
/projects/zOther/Test/test.txt,v  <--  test.txt
new revision: 1.12; previous revision: 1.11
done

e:\projects\zother\test>cvs editors

e:\projects\zother\test>cvs unedit test.txt

--- sequence 2: edit -z -----------------------------------
e:\projects\zother\test>cvs edit -c -z  test.txt

e:\projects\zother\test>test.txt [modified and saved file]

e:\projects\zother\test>cvs -r commit -m "test" test.txt
Checking in test.txt;
/projects/zOther/Test/test.txt,v  <--  test.txt
new revision: 1.11; previous revision: 1.10
done

e:\projects\zother\test>cvs editors

e:\projects\zother\test>dir /hkm CVS\Base
 6/06/04  17:33              26  test.txt.gz

e:\projects\zother\test>cvs unedit test.txt
test.txt has been modified; revert changes? n

e:\projects\zother\test>
-----------------------------------------------------------



More information about the cvsnt mailing list
Download the latest CVSNT, TortosieCVS, WinCVS etc. for Windows 8 etc.
@CVSNT on Twitter   CVSNT on Facebook