GNU bug report logs - #52507
[PATCH] Option for vc-delete-file to keep file on disk

Previous Next

Package: emacs;

Reported by: Ashwin Kafle <ashwin <at> ashwink.com.np>

Date: Wed, 15 Dec 2021 12:56:02 UTC

Severity: normal

Merged with 52508

Done: Sean Whitton <spwhitton <at> spwhitton.name>

Bug is archived. No further changes may be made.

Full log


Message #91 received at 52507 <at> debbugs.gnu.org (full text, mbox):

From: Ashwin Kafle <ashwin <at> ashwink.com.np>
To: Dmitry Gutov <dgutov <at> yandex.ru>
Cc: 52507 <at> debbugs.gnu.org, Ashwin Kafle <ashwin <at> ashwink.com.np>,
 Juri Linkov <juri <at> linkov.net>
Subject: Re: bug#52507: [PATCH] Option for vc-delete-file to keep file on disk
Date: Mon, 27 Dec 2021 04:08:50 +0000
Dmitry Gutov <dgutov <at> yandex.ru> writes:
>>> But the file would stay around, right? That would be different.
>> Only if you give vc-delete-file a prefix argument, otherwise it'll
>> be
>> exactly the same.  It will delete even if we use git rm --cached (because
>> it is checked later if the file exists anymore or not)
>
> OK, that seems to make sense. But how would we convey to the user that
> that "removed" (followed by "unregistered") refers to the staging
> area?
>

By mentioning it in the manual or perhaps in the docstring of
vc-delete-file?  It should be intuitive enough once you do it.

> 
> Patch which would implement this in VC-Dir/Git is welcome.

Can you please explain to me briefly how vc-dir gets this info?  I will
try at it but if you don't hear from me in a week then you know what
happened ;-)

On a related note, how do you test patches?  Last time i had to manually
C-M-x each and every function that was changed.  Is there a way to tell
emacs to ignore byte compiled files so as a simple restart will apply
new changes?  Any other way is okay with me too. 

>
> And the next step would be to ensure that such deletions (which keep
> the file on disk) can be committed by vc-next-action.
>

If it shows the two files, then you can mark the one saying removed and
vc-next-action can commit it.




This bug report was last modified 166 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.