GNU bug report logs - #68443
30.0.50; Cannot commit from *vc-diff* if there is a deleted file.

Previous Next

Package: emacs;

Reported by: Aleksandr Vityazev <avityazev <at> disroot.org>

Date: Sun, 14 Jan 2024 08:01:03 UTC

Severity: normal

Found in version 30.0.50

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dmitry Gutov <dmitry <at> gutov.dev>
Cc: 68443 <at> debbugs.gnu.org, avityazev <at> disroot.org
Subject: bug#68443: 30.0.50; Cannot commit from *vc-diff* if there is a deleted file.
Date: Wed, 17 Jan 2024 13:34:31 +0200
> Date: Wed, 17 Jan 2024 06:25:34 +0200
> From: Dmitry Gutov <dmitry <at> gutov.dev>
> 
> Try the patch below, seems to work here:
> 
> diff --git a/lisp/vc/diff-mode.el b/lisp/vc/diff-mode.el
> index 03efe0fdb31..83d580d98dd 100644
> --- a/lisp/vc/diff-mode.el
> +++ b/lisp/vc/diff-mode.el
> @@ -3014,7 +3014,7 @@ diff-vc-deduce-fileset
>         (goto-char (point-min))
>         (while (progn (diff-file-next) (not (eobp)))
>           (push (diff-find-file-name nil t) files)))
> -    (list backend (nreverse files) nil nil 'patch)))
> +    (list backend (delete nil (nreverse files)) nil nil 'patch)))
> 
>   (defun diff--filter-substring (str)
>     (when diff-font-lock-prettify
> 
> 
> (Eli, would this be suitable for emacs-29?)

Yes, thanks.  Just do it soon, please, if you can.




This bug report was last modified 1 year and 153 days ago.

Previous Next


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