From 7fb9b84449268c1f6bbc9451359f5c57fd6627f6 Mon Sep 17 00:00:00 2001 From: Daniel Borchmann Date: Sun, 19 Feb 2023 12:44:46 +0100 Subject: [PATCH] Do not refresh non-selected magit status buffers on Windows This setting is experimental and a test whether performance on Windows can be increased this way without causing too much confusion. --- init.el | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/init.el b/init.el index c6eea82..25d5b35 100644 --- a/init.el +++ b/init.el @@ -1532,8 +1532,16 @@ point to the beginning of buffer first." :ensure t :commands (magit-status magit-list-repositories) - :init (setq magit-diff-refine-hunk nil - magit-commit-show-diff nil) + + :init (progn + (setq magit-diff-refine-hunk nil + magit-commit-show-diff nil) + + (when on-windows + ;; Experimental: on Windows, do not refresh magit-status-buffers + ;; that are not select, to increase performance. + (setq magit-refresh-status-buffer nil))) + :config (progn (when (fboundp 'global-magit-file-mode) (global-magit-file-mode -1))