feat(picker.git): allow passing extra args to git grep. Closes #1184

This commit is contained in:
Folke Lemaitre 2025-02-15 07:13:41 +01:00
parent 72ffb3d1a2
commit 7122a03fdf
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040
2 changed files with 2 additions and 0 deletions

View file

@ -44,6 +44,7 @@ function M.grep(opts, ctx)
elseif opts.submodules then
table.insert(args, "--recurse-submodules")
end
vim.list_extend(args, opts.args or {})
table.insert(args, ctx.filter.search)
if not opts.cwd then
opts.cwd = Snacks.git.get_root() or uv.cwd() or "."