From 02e0c2fc4156c864a82758684ff101da1f4db7e2 Mon Sep 17 00:00:00 2001 From: Mohit Thatte Date: Wed, 6 Apr 2016 22:31:29 +0530 Subject: [PATCH] Add a hook to magit that notifies diff-hl - as per the diff-hl-mode README If you're using a version before 2.4.0, it defines magit-revert-buffer-hook (or magit-not-reverted-hook), which we use. When using Magit 2.4 or newer, add this to your init script: (add-hook 'magit-post-refresh-hook 'diff-hl-magit-post-refresh) --- core/prelude-editor.el | 1 + 1 file changed, 1 insertion(+) diff --git a/core/prelude-editor.el b/core/prelude-editor.el index 4d50c27..7829e55 100644 --- a/core/prelude-editor.el +++ b/core/prelude-editor.el @@ -392,6 +392,7 @@ indent yanked text (with prefix arg don't indent)." ;; diff-hl (global-diff-hl-mode +1) (add-hook 'dired-mode-hook 'diff-hl-dired-mode) +(add-hook 'magit-post-refresh-hook 'diff-hl-magit-post-refresh) ;; easy-kill (global-set-key [remap kill-ring-save] 'easy-kill)