mirror of
https://github.com/LazyVim/LazyVim.git
synced 2026-07-25 14:01:06 +00:00
feat(fzf): Add ability to send additional flags to ripgrep
This commit is contained in:
parent
fb59a9feb0
commit
7d96157817
1 changed files with 9 additions and 0 deletions
|
|
@ -167,6 +167,15 @@ return {
|
|||
},
|
||||
},
|
||||
grep = {
|
||||
rg_glob = true,
|
||||
-- first returned string is the new search query
|
||||
-- second returned string are (optional) additional rg flags
|
||||
-- @return string, string?
|
||||
rg_glob_fn = function(query)
|
||||
local regex, flags = query:match("^(.-)%s%-%-(.*)$")
|
||||
-- If no separator is detected will return the original query
|
||||
return (regex or query), flags
|
||||
end,
|
||||
actions = {
|
||||
["alt-i"] = { actions.toggle_ignore },
|
||||
["alt-h"] = { actions.toggle_hidden },
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue