diff options
author | Martin Polden <mpolden@mpolden.no> | 2020-01-28 20:50:33 +0100 |
---|---|---|
committer | Martin Polden <mpolden@mpolden.no> | 2020-01-28 20:50:33 +0100 |
commit | aecb788b7497a2f3ec0d91d6e03c71a6f4467f35 (patch) | |
tree | 36cdc854440ea661e5fc398fae3858238a04624e | |
parent | aba585c7d8ca0627cc77272b18309b51296a65aa (diff) |
Configure Swiper
-rw-r--r-- | init.el | 1 | ||||
-rw-r--r-- | lisp/init-ivy.el | 6 | ||||
-rw-r--r-- | lisp/init-swiper.el | 7 |
3 files changed, 12 insertions, 2 deletions
@@ -36,6 +36,7 @@ (require 'init-ibuffer) (require 'init-imenu) (require 'init-ivy) +(require 'init-swiper) ;; managing code (require 'init-eglot) diff --git a/lisp/init-ivy.el b/lisp/init-ivy.el index 63f75fc..ca57ca1 100644 --- a/lisp/init-ivy.el +++ b/lisp/init-ivy.el @@ -6,9 +6,11 @@ :diminish ivy-mode :commands ivy-mode :init - ;; use fuzzy matching by default (setq ivy-re-builders-alist - '((t . ivy--regex-fuzzy))) + ;; use regular matching in swiper + '((swiper . ivy--regex-plus) + ;; use fuzzy matching by default' + (t . ivy--regex-fuzzy))) :bind (:map ivy-minibuffer-map ;; C-r selects previous candidate, like isearch ("C-r" . ivy-previous-line-or-history)) diff --git a/lisp/init-swiper.el b/lisp/init-swiper.el new file mode 100644 index 0000000..90c1665 --- /dev/null +++ b/lisp/init-swiper.el @@ -0,0 +1,7 @@ +(use-package swiper + :bind (("C-s" . swiper) + ;; C-r selects previous candidate, like isearch + :map swiper-isearch-map + ("C-r" . ivy-previous-line-or-history))) + +(provide 'init-swiper) |