From 1e1fd5c8e45382034f53d2a617697b2ba75bcc42 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 25 Mar 2025 17:58:11 -0400 Subject: [PATCH] fix(magit): evil-collection-magit-section overrides These fixes for evil-collection-magit-section weren't being applied since 2f7f37d49b94, but any combination of `after!` (or `{with-}eval-after-load`) will convolute load order for users trying to rebind their own keys on top of ours *and* evil-collection's, and using `evil-collection-setup-hook` for this is clumsy, so I must resort to advice. Amend: 2f7f37d49b94 --- modules/tools/magit/config.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/tools/magit/config.el b/modules/tools/magit/config.el index 8cc62947c..49f5dc97d 100644 --- a/modules/tools/magit/config.el +++ b/modules/tools/magit/config.el @@ -258,7 +258,9 @@ Only has an effect in GUI Emacs.") :defer t :init (defvar evil-collection-magit-section-use-z-for-folds evil-collection-magit-use-z-for-folds) - (after! magit-section + :config + (defadvice! +magit--override-evil-collection-defaults-a (&rest _) + :after #'evil-collection-magit-section-setup ;; These numbered keys mask the numerical prefix keys. Since they've already ;; been replaced with z1, z2, z3, etc (and 0 with g=), there's no need to ;; keep them around: