From 901800109697f906d7eb2cf433dbcd3c5ed256f4 Mon Sep 17 00:00:00 2001 From: David Morgan Date: Wed, 12 Oct 2022 13:32:55 +0100 Subject: Move affe config into init-search.el --- .emacs.d/lisp/init-navigation.el | 27 --------------------------- .emacs.d/lisp/init-search.el | 27 +++++++++++++++++++++++++++ 2 files changed, 27 insertions(+), 27 deletions(-) (limited to '.emacs.d/lisp') diff --git a/.emacs.d/lisp/init-navigation.el b/.emacs.d/lisp/init-navigation.el index cb2a39e..e41eb9e 100644 --- a/.emacs.d/lisp/init-navigation.el +++ b/.emacs.d/lisp/init-navigation.el @@ -40,33 +40,6 @@ ("M-P" . symbol-overlay-switch-backward) ("" . symbol-overlay-remove-all)) -(use-package affe - :after (consult orderless) - :config - (setq affe-grep-command (replace-regexp-in-string "\\." "-Suu ." affe-grep-command)) - ;; Configure Orderless - (defun affe-orderless-regexp-compiler (input _type _ignorecase) - (setq input (orderless-pattern-compiler input)) - (cons input (lambda (str) (orderless--highlight input str)))) - (setq affe-regexp-compiler #'affe-orderless-regexp-compiler) - ;; Manual preview key for `affe-grep' - (consult-customize affe-grep :preview-key (kbd "M-.")) - (defun my/affe-grep-symbol-at-point (&optional dir initial) - (interactive - (list prefix-arg (when-let ((s (symbol-at-point))) - (symbol-name s)))) - (affe-grep dir initial)) - (defun my/affe-find-symbol-at-point (&optional dir initial) - (interactive - (list prefix-arg (when-let ((s (symbol-at-point))) - (symbol-name s)))) - (affe-find dir initial)) - :bind - ("C-#" . affe-grep) - ("C-c z" . affe-find) - ("C-c Z" . my/affe-find-symbol-at-point) - ("C-~" . my/affe-grep-symbol-at-point)) - (use-package gumshoe :defer 5 :after perspective diff --git a/.emacs.d/lisp/init-search.el b/.emacs.d/lisp/init-search.el index b3986ec..38aceb4 100644 --- a/.emacs.d/lisp/init-search.el +++ b/.emacs.d/lisp/init-search.el @@ -46,5 +46,32 @@ (use-package deadgrep) +(use-package affe + :after (consult orderless) + :config + (setq affe-grep-command (replace-regexp-in-string "\\." "-Suu ." affe-grep-command)) + ;; Configure Orderless + (defun affe-orderless-regexp-compiler (input _type _ignorecase) + (setq input (orderless-pattern-compiler input)) + (cons input (lambda (str) (orderless--highlight input str)))) + (setq affe-regexp-compiler #'affe-orderless-regexp-compiler) + ;; Manual preview key for `affe-grep' + (consult-customize affe-grep :preview-key (kbd "M-.")) + (defun my/affe-grep-symbol-at-point (&optional dir initial) + (interactive + (list prefix-arg (when-let ((s (symbol-at-point))) + (symbol-name s)))) + (affe-grep dir initial)) + (defun my/affe-find-symbol-at-point (&optional dir initial) + (interactive + (list prefix-arg (when-let ((s (symbol-at-point))) + (symbol-name s)))) + (affe-find dir initial)) + :bind + ("C-#" . affe-grep) + ("C-c z" . affe-find) + ("C-c Z" . my/affe-find-symbol-at-point) + ("C-~" . my/affe-grep-symbol-at-point)) + (provide 'init-search) ;;; init-search.el ends here -- cgit 1.4.1-2-gfad0 in/WWW/Library/Implementation/HTGopher.h?id=e087f6d44e87f489fcb3056e86319ebba4218156'>plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27