Skip to content

Commit

Permalink
live_grep_glob: start showing results as soon as separator is found
Browse files Browse the repository at this point in the history
  • Loading branch information
ibhagwan committed Apr 9, 2022
1 parent 7557d90 commit 58320a2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/fzf-lua/make_entry.lua
Original file line number Diff line number Diff line change
Expand Up @@ -213,10 +213,10 @@ M.glob_parse = function(opts, query)
if config.globals.grep.rg_glob_fn then
return config.globals.grep.rg_glob_fn(opts, query)
end
local glob_args = nil
local glob_args = ""
local search_query, glob_str = query:match("(.*)"..opts.glob_separator.."(.*)")
for _, s in ipairs(utils.strsplit(glob_str, "%s")) do
glob_args = (glob_args or "") .. ("%s %s ")
glob_args = glob_args .. ("%s %s ")
:format(opts.glob_flag, vim.fn.shellescape(s))
end
return search_query, glob_args
Expand Down

0 comments on commit 58320a2

Please sign in to comment.