From d6bfdff3c262d9f36ec1a9b2e3f502336d37e79f Mon Sep 17 00:00:00 2001 From: Bozhidar Batsov Date: Sat, 28 Feb 2026 10:07:02 +0200 Subject: Skip projectile-maybe-limit-project-file-buffers on TRAMP The buffer-limiting function was called before the file-remote-p guard in projectile-find-file-hook-function, triggering expensive buffer enumeration and file-truename calls on every remote file open. Move it inside the existing TRAMP guard. --- projectile.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projectile.el b/projectile.el index 4a252e3..9f12976 100644 --- a/projectile.el +++ b/projectile.el @@ -6454,8 +6454,8 @@ Magit that don't trigger `find-file-hook'." The function does pretty much nothing when triggered on remote files as all the operations it normally performs are extremely slow over tramp." - (projectile-maybe-limit-project-file-buffers) (unless (file-remote-p default-directory) + (projectile-maybe-limit-project-file-buffers) (when projectile-dynamic-mode-line (projectile-update-mode-line)) (when projectile-auto-update-cache -- cgit v1.0