From c28bb1519d753d63627671ab867fff958b6cbe94 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Mon, 3 Oct 2016 12:10:52 +0200 Subject: [PATCH] Extract ivy config into core-ivy.el --- core/core-editor.el | 3 +-- core/core-ivy.el | 7 ++++--- core/core-yasnippet.el | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/core-editor.el b/core/core-editor.el index 10f4de248..76b3e6bef 100644 --- a/core/core-editor.el +++ b/core/core-editor.el @@ -278,8 +278,7 @@ (use-package smex :commands (smex smex-major-mode-commands) :config - (setq smex-completion-method 'ivy - smex-save-file (concat doom-temp-dir "/smex-items")) + (setq smex-save-file (concat doom-temp-dir "/smex-items")) (smex-initialize)) (use-package swiper :commands (swiper swiper-all)) diff --git a/core/core-ivy.el b/core/core-ivy.el index 7c5ddc113..b8f5455c9 100644 --- a/core/core-ivy.el +++ b/core/core-ivy.el @@ -9,9 +9,6 @@ ivy-wrap t) :config - (after! magit - (setq magit-completing-read-function 'ivy-completing-read)) - (ivy-mode +1) (map! :map ivy-minibuffer-map [escape] 'keyboard-escape-quit @@ -24,6 +21,10 @@ ;; Fix display glitches (advice-add 'ivy-done :after 'redraw-display) + (after! magit (setq magit-completing-read-function 'ivy-completing-read)) + (after! smex (setq smex-completion-method 'ivy)) + (after! yasnippet (push 'doom/yas-ivy-prompt yas-prompt-functions)) + ;; (require 'counsel) diff --git a/core/core-yasnippet.el b/core/core-yasnippet.el index ee4ae933f..c009ddf2e 100644 --- a/core/core-yasnippet.el +++ b/core/core-yasnippet.el @@ -13,7 +13,7 @@ (setq yas-verbosity 0 yas-indent-line 'auto yas-also-auto-indent-first-line t - yas-prompt-functions '(doom/yas-ivy-prompt yas-ido-prompt yas-no-prompt) + yas-prompt-functions '(yas-ido-prompt yas-no-prompt) ;; Only load personal snippets yas-snippet-dirs (list (concat doom-private-dir "/snippets") (concat doom-private-dir "/templates")))