Skip to main content
update: the solution works pretty well
Source Link
Khoa Vo
  • 111
  • 4

Leaning on the built-in isearch, the custom variable search-whitespace-regexp and these key bindings seem to do itworks pretty well for me.

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Note: In the above example, "n" and "N" don't behave exactly like evil mode since they always go in the same direction every time. You can easily configure that though.

Leaning on the built-in isearch, the custom variable search-whitespace-regexp and these key bindings seem to do it for me

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Note: "n" and "N" don't behave exactly like evil mode since they always go in the same direction every time.

Leaning on the built-in isearch, the custom variable search-whitespace-regexp and these key bindings works pretty well for me.

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Note: In the above example, "n" and "N" don't behave exactly like evil mode since they always go in the same direction every time. You can easily configure that though.

added 145 characters in body
Source Link
Khoa Vo
  • 111
  • 4

TheLeaning on the built-in isearch, the custom variable search-whitespace-regexp and these key bindings seem to do it for me

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Note: "n" and "N" don't behave exactly like evil mode since they always go in the same direction every time.

The custom variable search-whitespace-regexp and these key bindings seem to do it for me

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Leaning on the built-in isearch, the custom variable search-whitespace-regexp and these key bindings seem to do it for me

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.

Note: "n" and "N" don't behave exactly like evil mode since they always go in the same direction every time.

Source Link
Khoa Vo
  • 111
  • 4

The custom variable search-whitespace-regexp and these key bindings seem to do it for me

(custom-set-variables '(search-whitespace-regexp ".*"))
(evil-define-key '(normal) 'global "/" (lambda () (interactive) (isearch-forward)))
(evil-define-key '(normal) 'global "?" (lambda () (interactive) (isearch-backward)))
(evil-define-key '(normal) 'global "n" (lambda () (interactive) (isearch-repeat-forward)))
(evil-define-key '(normal) 'global "N" (lambda () (interactive) (isearch-repeat-backward)))

I don't know if it really works out in the long term since I've only figured it out just now. But putting here in case it's useful for anyone.

Or you can use swiper (which I think does fuzzy matching by default) but it's pretty slow and I don't need the preview feature. But it worked fine for me in the past.