diff --git a/modules/editor/evil/init.el b/modules/editor/evil/init.el index 40a1f2805..1674bceb4 100644 --- a/modules/editor/evil/init.el +++ b/modules/editor/evil/init.el @@ -17,9 +17,9 @@ ;; disable modules, and to reduce the effort required to maintain our copy of ;; `evil-collection-list' (now I can just copy it from time to time). -(when (and (featurep! +everywhere) - doom-interactive-mode - (not doom-reloading-p)) +(when (and doom-interactive-mode + (not doom-reloading-p) + (featurep! +everywhere)) (setq evil-collection-company-use-tng (featurep! :completion company +tng) ;; must be set before evil/evil-collection is loaded diff --git a/modules/ui/vc-gutter/config.el b/modules/ui/vc-gutter/config.el index 27a2ff6cc..4264f13a7 100644 --- a/modules/ui/vc-gutter/config.el +++ b/modules/ui/vc-gutter/config.el @@ -51,23 +51,20 @@ is deferred until the file is saved. Respects `git-gutter:disabled-modes'." (git-gutter-mode +1) (remove-hook 'after-save-hook #'+vc-gutter-init-maybe-h 'local))))))) - ;; Disable in Org mode, as per - ;; and - ;; . Apparently, the - ;; mode-enabling function for global minor modes gets called for new buffers - ;; while they are still in `fundamental-mode', before a major mode has been - ;; assigned. I don't know why this is the case, but adding `fundamental-mode' - ;; here fixes the issue. + ;; Disable in Org mode, as per syl20bnr/spacemacs#10555 and + ;; syohex/emacs-git-gutter#24. Apparently, the mode-enabling function for + ;; global minor modes gets called for new buffers while they are still in + ;; `fundamental-mode', before a major mode has been assigned. I don't know why + ;; this is the case, but adding `fundamental-mode' here fixes the issue. (setq git-gutter:disabled-modes '(fundamental-mode image-mode pdf-view-mode)) :config + (set-popup-rule! "^\\*git-gutter" :select nil :size '+popup-shrink-to-fit) + ;; Only enable the backends that are available, so it doesn't have to check ;; when opening each buffer. - (setq git-gutter:handled-backends '(git)) - (dolist (backend '(hg svn bzr)) - (when (executable-find (symbol-name backend)) - (add-to-list 'git-gutter:handled-backends backend))) - - (set-popup-rule! "^\\*git-gutter" :select nil :size '+popup-shrink-to-fit) + (setq git-gutter:handled-backends + (cons 'git (cl-remove-if-not #'executable-find (list 'hg 'svn 'bzr) + :key #'symbol-name))) ;; Update git-gutter on focus (in case I was using git externally) (add-hook 'focus-in-hook #'git-gutter:update-all-windows)