Emacs: Don't fuzzy search in consult-line

This commit is contained in:
Riyyi
2023-08-12 11:53:51 +02:00
parent 9f5ce80255
commit 1fb041fffc
2 changed files with 14 additions and 2 deletions
+2 -1
View File
@@ -505,7 +505,8 @@
"s l" '(avy-goto-line :which-key "Avy goto line")
"s p" '(consult-grep :which-key "Search project")
"s q" '(evil-ex-nohighlight :which-key "Stop search")
"s s" '(consult-line :which-key "Search buffer")
"s s" '(dot/consult-line-no-fuzzy :which-key "Search buffer")
"s S" '(consult-line-multi :which-key "Search all buffers")
;; Tabs / toggle
"t" '(:ignore t :which-key "tabs/toggle")
+12 -1
View File
@@ -58,7 +58,18 @@
(elpaca-setup consult
(:load-after vertico)
(:when-loaded (setq consult-narrow-key (kbd "?"))))
(:when-loaded
(setq consult-narrow-key (kbd "?"))
(defun dot/consult-line-no-fuzzy ()
"Call consult-line without fuzzy matching."
(interactive)
(let ((prescient-filter-method (delete 'fuzzy (copy-tree prescient-filter-method))))
(consult-line)))
(consult-customize
dot/consult-line-no-fuzzy :prompt "Search: "
consult-line-multi :prompt "Search: " :initial nil)))
(elpaca-setup consult-flycheck
(:load-after consult flycheck))