bug-cvs
[Top][All Lists]
Advanced

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

Re: After removing and (re)adding file is deleted without warning


From: Derek Robert Price
Subject: Re: After removing and (re)adding file is deleted without warning
Date: Thu, 06 Nov 2003 13:31:39 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 Netscape/7.1

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

andyreifREMOVE_IT@studcs.uni-sb.de wrote:

|On Wednesday 05 November 2003 16:52, andyreifREMOVE_IT@studcs.uni-sb.de
wrote:
|
|>It's actually a feature request, since those who know this issue won't run
|>into troubles.
|>
|>How to reproduce:
|>Create file.txt with a text editor.
|>cvs add file.txt
|>cvs commit
|>mv file.txt newfile.txt
|>cvs remove -f file.txt
|>Now you decide that the renaming is superfluous and want to undo the
|>changes: rm newfile.txt
|>Resave file.txt from the text editor.
|>cvs add file.txt
|>cvs add: file.txt should be removed and is still there (or is back again)
|> -> (adding is not done ( this should be stated more clearly! ), and this
|>might be forgotten by the user) Making _some changes_ to file.txt.
|>cvs commit -m "" -> file will be removed and _some changes_ will be lost
|>without warning, although from user's point of view this shouldn't be
done.
|>
|>How to solve: check the date of last change for repository and local
|>versions (like this is done for commit) and only if it "should't be
|>committed" (i.e. there are no changes after the most recent update/commit)
|>the file may be deleted without warnings. Otherwise (there are _some
|>changes_): the user should be advised what to do, i.e. moving the modified
|>files to a temporary directory and (re)adding them later, or perhaps this
|>could be done by cvs some day?
|
|
|IMHO it would be better to ignore the cvs remove command if it is
followed by
|an add command on the same file.
|I do not think this would cause problems, since it is only a local copy
issue,
|and it is something that user supposes to happen.
|
|If the user had performed cvs remove and then has made some changes to
a file,
|he/she should be warned about this (perhaps with a possibility to
abort, like
|the one when you try to commit and have not typed anything into
editor), and
|if he/she still decides to proceed, this file should at least be backuped,
|e.g. with the .# prefix (as this is done for files that are going to be
|merged). In this case the changes would not be lost as it happens
currently.
|
|Any comments?


Could you produce a sanity.sh test case for this failure?

Derek

- --
~                *8^)

Email: derek@ximbiot.com

Get CVS support at <http://ximbiot.com>!
- --
106.  Charlie was a Chemist, but Charlie is no more.
~      What Charlie thought was H20 was H2SO4.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Using GnuPG with Netscape - http://enigmail.mozdev.org

iD8DBQE/qpOLLD1OTBfyMaQRAmOhAKD/XQEft/diYiES9lQEB5R4mMfnVgCgzNSL
3kj6ObaqUciuq5kvxH1Vrr8=
=Krv0
-----END PGP SIGNATURE-----






reply via email to

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