GNU bug report logs - #78987
30.1; Unable to create new Git repository in Dired mode

Previous Next

Package: emacs;

Reported by: "Zipei Lu" <zipeilu <at> qq.com>

Date: Wed, 9 Jul 2025 21:57:09 UTC

Severity: normal

Found in version 30.1

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

Bug is archived. No further changes may be made.

Full log


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

From: Stephen Berman <stephen.berman <at> gmx.net>
To: Sean Whitton <spwhitton <at> spwhitton.name>
Cc: zipeilu <at> qq.com, 78987 <at> debbugs.gnu.org
Subject: Re: bug#78987: 30.1; Unable to create new Git repository in Dired mode
Date: Fri, 11 Jul 2025 11:33:51 +0200
On Fri, 11 Jul 2025 10:05:00 +0100 Sean Whitton <spwhitton <at> spwhitton.name> wrote:

> Hello,
>
> On Fri 11 Jul 2025 at 09:36am +01, Sean Whitton wrote:
>
>>> diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
>>> index e5b08af2a30..d8b195d9a12 100644
>>> --- a/lisp/dired-aux.el
>>> +++ b/lisp/dired-aux.el
>>> @@ -4022,8 +4022,9 @@ dired-vc-next-action
>>>  ;;;###autoload
>>>  (defun dired-vc-deduce-fileset
>>>      (&optional state-model-only-files not-state-changing)
>>> -  (let ((backend (vc-responsible-backend default-directory))
>>> -        (files (dired-get-marked-files nil nil nil nil t)))
>>> +  (let* ((files (dired-get-marked-files nil nil nil nil t))
>>> +         (backend (or (vc-responsible-backend default-directory t)
>>> +                      (vc-backend-for-registration (car files)))))
>>>      (when (and (not not-state-changing)
>>>                 (cl-some #'file-directory-p files))
>>>        (user-error "\
>>
>> I think this is okay, please install.
>
> No, wait.  I think that we need to pass down the allow-unregistered
> argument from vc-deduce-fileset to dired-vc-deduce-fileset, and only
> if that's non-nil can we call vc-backend-for-registration.

When I test with -Q, a Git repository is created and either the file at
point or the marked files in Dired are added to it, although
`vc-deduce-fileset' calls `(dired-vc-deduce-fileset
state-model-only-files not-state-changing)', i.e., without passing
`allow-unregistered'; so why do you think it must be passed (and
non-nil)?

Steve Berman




This bug report was last modified 31 days ago.

Previous Next


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