From 978366ba46e2306b60ef64bd9e51a6c758fe48f0 Mon Sep 17 00:00:00 2001 From: Chase Colman <5411+chase@users.noreply.github.com> Date: Sun, 12 Sep 2021 17:37:04 +0800 Subject: [PATCH] fix: add no more flags delimiter for ripgrep (#1217) This matches the behavior of fzf, if a user needs to pass additional arguments they can use additional_args or change vimgrep_arguments. --- lua/telescope/builtin/files.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lua/telescope/builtin/files.lua b/lua/telescope/builtin/files.lua index 09a0bea..8b005bc 100644 --- a/lua/telescope/builtin/files.lua +++ b/lua/telescope/builtin/files.lua @@ -93,7 +93,7 @@ files.live_grep = function(opts) search_list = filelist end - return flatten { vimgrep_arguments, additional_args, prompt, search_list } + return flatten { vimgrep_arguments, additional_args, "--", prompt, search_list } end, opts.entry_maker or make_entry.gen_from_vimgrep( opts ), opts.max_results, opts.cwd) @@ -131,6 +131,7 @@ files.grep_string = function(opts) vimgrep_arguments, additional_args, word_match, + "--", search, }