From 67a83e2466ea8b7abc74141f887fd39a1e9016cb Mon Sep 17 00:00:00 2001 From: Skladnayazebra Date: Thu, 9 Apr 2026 12:20:42 +0200 Subject: reconfigure treesitter for NeoVim 0.12; move stuff around --- nvim/lua/config/plugins/tree-sitter.lua | 40 ++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 18 deletions(-) (limited to 'nvim/lua/config/plugins') diff --git a/nvim/lua/config/plugins/tree-sitter.lua b/nvim/lua/config/plugins/tree-sitter.lua index d37f98b..a692c37 100644 --- a/nvim/lua/config/plugins/tree-sitter.lua +++ b/nvim/lua/config/plugins/tree-sitter.lua @@ -1,27 +1,31 @@ return { { "nvim-treesitter/nvim-treesitter", - branch = 'master', + branch = 'main', lazy = false, build = ":TSUpdate", config = function() - require'nvim-treesitter.configs'.setup { - -- A list of parser names, or "all" (the listed parsers MUST always be installed) - ensure_installed = { "c", "lua", "vim", "vimdoc", "query", "markdown", "markdown_inline" }, - - -- Automatically install missing parsers when entering buffer - -- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally - auto_install = true, - - highlight = { - enable = true, - -- Setting this to true will run `:h syntax` and tree-sitter at the same time. - -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation). - -- Using this option may slow down your editor, and you may see some duplicate highlights. - -- Instead of true it can also be a list of languages - additional_vim_regex_highlighting = false, - }, - } + require('nvim-treesitter').install { + "bash", + "c", + "css", + "gitignore", + "html", + "ini", -- .npmrc + "javascript", + "json", + "lua", + "lua", + "markdown", + "markdown_inline", -- code blocks inside .md + "query", + "scss", + "tsx", + "typescript", + "vim", + "vimdoc", + "yaml", + } end } } -- cgit v1.3.1