[darcs-devel] [darcs #396] 'darcs record' should respect
registered files
Karel Gardas
kgardas at objectsecurity.com
Thu May 19 03:35:57 PDT 2005
On Thu, 19 May 2005, Erik Schnetter wrote:
>> My proposal is:
>> 1) add --look-for-removes option to record, which will disable file
>> existence checking logic
>
> Sounds good.
>
>> 2) change help comment in remove command and omit sentence:
>> "Otherwise just delete the file or directory, and darcs will notice
>> that it has been removed."
>>
>> The idea behind my proposal is to make add and remove plus record
>> more "symetric".
>
> If add and remove are to be symmetric, and if add requires the file to
> be present, then remove should require the file to be not present
> (unless overridden e.g. by a --force option, which should then also
> exist for add). This would eliminate the surprise that you can remove
> a file from your repository while keeping the file, but the file is
> actually deleted in other repositories when the patch is applied.
Sorry for my bad explanation. I think my idea is about this invariant: set
of files in darcs repo is a subset of a set of files on FS. i.e. you
should really first remove file from darcs repo and then from the FS. I
don't think that appling a patch with file removal hunk which removes file
from the repository and then from the FS is a surprise. IMHO this is
expected behaviour, well except when darcs removes file to which you've
made some changes, but that should be considered as a bug. -- and I hope
this is not the darcs case. :-)
Thanks,
Karel
--
Karel Gardas kgardas at objectsecurity.com
ObjectSecurity Ltd. http://www.objectsecurity.com
More information about the darcs-devel
mailing list