1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-02-15 23:39:27 +08:00

fix(flygrep): skip E33 when input is ~

This commit is contained in:
Eric Wong 2025-02-03 01:04:33 +08:00
parent 6d72766f36
commit d3939573cc
No known key found for this signature in database
GPG Key ID: 41BB7053E835C848

View File

@ -345,7 +345,7 @@ local function open_win()
pcall(vim.fn.timer_stop, grep_timer_id)
job.stop(search_jobid)
search_hi_id =
vim.fn.matchadd(conf.matched_higroup, grep_input, 10, -1, { window = result_winid })
vim.fn.matchadd(conf.matched_higroup, grep_input:gsub('~', '\\~'), 10, -1, { window = result_winid })
grep_timer_id = vim.fn.timer_start(conf.timeout, grep_timer, { ['repeat'] = 1 })
else
pcall(vim.fn.matchdelete, search_hi_id, result_winid)