From 9766a5bec861be7fcaec3bd2574ba52ffdb11179 Mon Sep 17 00:00:00 2001 From: Oleg Matrokhin Date: Thu, 17 Sep 2020 00:09:12 +0300 Subject: fix: use double dash to fix special filenames (#87) Co-authored-by: Oleg Matrokhin --- lua/telescope/builtin.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lua/telescope/builtin.lua') diff --git a/lua/telescope/builtin.lua b/lua/telescope/builtin.lua index 8f7f5db..606914b 100644 --- a/lua/telescope/builtin.lua +++ b/lua/telescope/builtin.lua @@ -115,7 +115,7 @@ builtin.live_grep = function(opts) return nil end - return flatten { conf.vimgrep_arguments, prompt } + return flatten { conf.vimgrep_arguments, " --", prompt } end, opts.entry_maker or make_entry.gen_from_vimgrep(opts), opts.max_results or 1000 @@ -346,7 +346,7 @@ builtin.grep_string = function(opts) pickers.new(opts, { prompt = 'Find Word', finder = finders.new_oneshot_job( - flatten { conf.vimgrep_arguments, search}, + flatten { conf.vimgrep_arguments, " --", search}, opts ), previewer = previewers.vimgrep.new(opts), -- cgit v1.2.3