Subject: Re: bug#78572: 30.1; Tramp Project error message loop - File is missing

From: Michael Albinus <[email-masked]>
Date: Thu, 29 May 2025 09:25:36 +0200

Ship Mints <[email-masked]> writes:

Hi Stephane,

> If this continues to be a concern, you can easily wrap the project
> mode line with a remote file guard.  Maybe something like this:
>
>   (setq project-mode-line-format '(:eval
> (my/project-mode-line-format)))
>   (defun my/project-mode-line-format ()
>     (unless (file-remote-p default-directory)
>       (project-mode-line-format)))

We have without-remote-files for this. So you could use instead

--8<---------------cut here---------------start------------->8---
(add-function
 :around (symbol-function #'project-mode-line-format) #'without-remote-files)
--8<---------------cut here---------------end--------------->8---

> -Stephane

Best regards, Michael.