fix advanced search auto globbing feature
This commit is contained in:
@@ -27,7 +27,13 @@ local advanced_grep = function(opts)
|
||||
|
||||
if pieces[2] then
|
||||
table.insert(args, "-g")
|
||||
table.insert(args, pieces[2])
|
||||
|
||||
local input_glob = pieces[2]
|
||||
local glob = input_glob
|
||||
if not input_glob:find("*", 1, true) then
|
||||
glob = '**/*' .. input_glob .. '*/**'
|
||||
end
|
||||
table.insert(args, glob)
|
||||
end
|
||||
|
||||
return vim.iter({ args, { "--color=never", "--no-heading", "--with-filename", "--line-number", "--column", "--smart-case" } })
|
||||
|
||||
Reference in New Issue
Block a user