use xmap instead of vmap in textobjects

This commit is contained in:
evakuator 2020-09-01 21:44:24 +06:00 committed by Stephan Seitz
parent acba0fd666
commit c5d5e48e0f
2 changed files with 3 additions and 3 deletions

View file

@ -100,7 +100,7 @@ function M.attach(bufnr)
if funcname == "init_selection" then
mode = 'n'
else
mode = 'v'
mode = 'x'
end
local cmd = string.format(":lua require'nvim-treesitter.incremental_selection'.%s()<CR>", funcname)
api.nvim_buf_set_keymap(bufnr, mode, mapping, cmd, { silent = true, noremap = true })