completion/ivy: turn off my "very magic" regex mod

This makes regex consistent between evil-search, ivy, ripgrep and ag.
This commit is contained in:
Henrik Lissner 2017-12-10 14:54:28 -05:00
parent ae25e319b0
commit a41f02e6e7
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
2 changed files with 3 additions and 6 deletions

View file

@ -144,8 +144,7 @@ counsel-rg)."
(let ((default-directory counsel--git-dir)
(regex (counsel-unquote-regex-parens
(setq ivy--old-re
(ivy--regex
(counsel-unquote-regex-parens string)))))) ;; #2
(ivy--regex string)))))
(let* ((args-end (string-match " -- " extra-ag-args))
(file (if args-end
(substring-no-properties extra-ag-args (+ args-end 3))

View file

@ -82,10 +82,8 @@ immediately runs it on the current candidate (ending the ivy session)."
'(("O" +ivy-git-grep-other-window-action "open in other window"))))
;; 1. Remove character limit from `counsel-ag-function'
;; 2. Disable ivy's over-zealous parentheses quoting behavior (if i want
;; literal parentheses, I'll escape them myself).
;; 3. This may need to be updated frequently, to meet changes upstream
;; 4. counsel-ag, counsel-rg and counsel-pt all use this function
;; 2. This may need to be updated frequently, to meet changes upstream
;; 3. counsel-ag, counsel-rg and counsel-pt all use this function
(advice-add #'counsel-ag-function :override #'+ivy*counsel-ag-function))