fix rg ignore option in non git projects

- Fix #46
- according to rg's manual, files for `--ignore-file FILE ...` should
  be matched relative to the current working directory
- while `--glob` can accept files that does not exist in current
  project (Thanks to @chaoyi)
This commit is contained in:
Yiming Chen 2017-08-05 17:17:19 +08:00
parent aefd25c747
commit 07ba798d76

View file

@ -254,7 +254,7 @@ BUFFER may be a string or nil."
(options
(concat options " "
(mapconcat (lambda (i)
(concat "--ignore-file " (shell-quote-argument i)))
(concat "--glob " (shell-quote-argument (concat "!" i))))
ignored
" "))))
(counsel-rg nil