From 82021c72d10c0c1b20551e373b7bc436faae65c5 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Fri, 29 Sep 2023 23:47:19 +0200 Subject: nvim: Add support for GSP textobjects --- .config/nvim/after/plugin/treesitter.lua | 6 ++++++ 1 file changed, 6 insertions(+) (limited to '.config/nvim') diff --git a/.config/nvim/after/plugin/treesitter.lua b/.config/nvim/after/plugin/treesitter.lua index ce7f273..49c21f2 100644 --- a/.config/nvim/after/plugin/treesitter.lua +++ b/.config/nvim/after/plugin/treesitter.lua @@ -50,6 +50,8 @@ require('nvim-treesitter.configs').setup { ['if'] = '@function.inner', ['ab'] = '@block.outer', ['ib'] = '@block.inner', + ['an'] = '@node.outer', + ['in'] = '@node.inner', }, }, move = { @@ -58,18 +60,22 @@ require('nvim-treesitter.configs').setup { goto_next_start = { [']f'] = '@function.outer', [']b'] = '@block.outer', + [']n'] = '@node.outer', }, goto_next_end = { [']F'] = '@function.outer', [']B'] = '@block.outer', + [']N'] = '@node.outer', }, goto_previous_start = { ['[f'] = '@function.outer', ['[b'] = '@block.outer', + ['[n'] = '@node.outer', }, goto_previous_end = { ['[F'] = '@function.outer', ['[B'] = '@block.outer', + ['[N'] = '@node.outer', }, }, }, -- cgit v1.2.3