bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#65704: 29.1; Most code of `project-ignores' seems to be dead code


From: Dmitry Gutov
Subject: bug#65704: 29.1; Most code of `project-ignores' seems to be dead code
Date: Thu, 7 Sep 2023 00:16:42 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0

On 06/09/2023 22:12, Damien Cassou wrote:
Dmitry Gutov<dmitry@gutov.dev>  writes:
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index 29a81c7e151..2eea0ef72e0 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -566,6 +566,12 @@ project-try-vc
                  (project--submodule-p root))
             (let* ((parent (file-name-directory (directory-file-name
root))))
               (setq root (vc-call-backend 'Git 'root parent))))
+        (when (not backend)
it seems that `root' is sometimes nil at this point so I would change
this line to

   (when (and (not backend) root)

I've used this for the day and it seems to work fine.

Thanks for the extra testing.

I just moved the new code a little deeper down inside (when root ...) block, should do the same. Pushed as 62229fb2d11 and bumped project.el version to 0.10.0.

Should be out in ELPA shortly along with a few other new features added recently.

This seems to resolve the last of the concerns here, so closing the bug as well. Please clarify if something remains.

Addendum regarding the chosen solution: I guess there is a downside or two: when working over Tramp, the latency will increase. And if the subproject's dir is in the parent's .gitignore, the behavior will get worse.

Let's wait for feedback to see if those are real problems, but worst case, the solution which you had used previously should take care at least of the second usage scenario (ignoring the ignores).





reply via email to

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