diff options
| author | elianiva <dicha.arkana03@gmail.com> | 2021-01-03 17:59:16 +0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-01-03 11:59:16 +0100 |
| commit | c3806f46b920f53b32e417f8c586b8bb3ed0d95e (patch) | |
| tree | 8e384c39b57896e0a37d010bfddb5af0579b5ce5 /lua | |
| parent | f15af583ebdce3c1b89cdfec05664c84e3d3ff51 (diff) | |
fix: live_grep throws an error if you insert `\` (#378)
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/telescope/builtin/files.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lua/telescope/builtin/files.lua b/lua/telescope/builtin/files.lua index 35e68be..f2d84fd 100644 --- a/lua/telescope/builtin/files.lua +++ b/lua/telescope/builtin/files.lua @@ -19,6 +19,8 @@ files.live_grep = function(opts) return nil end + if string.match(prompt, "[\\|%(%)]") then prompt = "" end + return flatten { conf.vimgrep_arguments, prompt } end, opts.entry_maker or make_entry.gen_from_vimgrep(opts), |
