emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/diff-hl c31af59 20/25: Don't hook into after-revert-hoo


From: Dmitry Gutov
Subject: [elpa] externals/diff-hl c31af59 20/25: Don't hook into after-revert-hook
Date: Sun, 20 Dec 2020 05:07:04 -0500 (EST)

branch: externals/diff-hl
commit c31af59cce04fdcf9d05da54a43d236a4869c251
Author: Dmitry Gutov <dgutov@yandex.ru>
Commit: Dmitry Gutov <dgutov@yandex.ru>

    Don't hook into after-revert-hook
    
    #152
---
 diff-hl.el | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/diff-hl.el b/diff-hl.el
index a816610..0f59263 100644
--- a/diff-hl.el
+++ b/diff-hl.el
@@ -573,13 +573,9 @@ The value of this variable is a mode line template as in
                     'find-file-hook)
                   'diff-hl-update t t)
         (add-hook 'vc-checkin-hook 'diff-hl-update nil t)
-        (add-hook 'after-revert-hook 'diff-hl-update nil t)
-        ;; Magit does call `auto-revert-handler', but it usually
-        ;; doesn't do much, because `buffer-stale--default-function'
-        ;; doesn't care about changed VC state.
         ;; https://github.com/magit/magit/issues/603
         (add-hook 'magit-revert-buffer-hook 'diff-hl-update nil t)
-        ;; Magit versions 2.0-2.3 don't do the above and call this
+        ;; Magit versions 2.0-2.3 don't use the above and call this
         ;; instead, but only when they don't call `revert-buffer':
         (add-hook 'magit-not-reverted-hook 'diff-hl-update nil t)
         (add-hook 'text-scale-mode-hook 'diff-hl-maybe-redefine-bitmaps nil t))
@@ -587,7 +583,6 @@ The value of this variable is a mode line template as in
     (remove-hook 'after-change-functions 'diff-hl-edit t)
     (remove-hook 'find-file-hook 'diff-hl-update t)
     (remove-hook 'vc-checkin-hook 'diff-hl-update t)
-    (remove-hook 'after-revert-hook 'diff-hl-update t)
     (remove-hook 'magit-revert-buffer-hook 'diff-hl-update t)
     (remove-hook 'magit-not-reverted-hook 'diff-hl-update t)
     (remove-hook 'text-scale-mode-hook 'diff-hl-maybe-redefine-bitmaps t)



reply via email to

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