diff options
| author | Jack Jamison <jackqjamison@gmail.com> | 2025-06-16 22:53:16 -0400 |
|---|---|---|
| committer | Jack Jamison <jackqjamison@gmail.com> | 2025-06-16 22:53:16 -0400 |
| commit | e72bc10296c0d4c145abd69a2b00bc8aad0004bb (patch) | |
| tree | af922e03fac17212db8da13937f4b2d562dd4037 /.config/nvim/lua/plugins/treesitter.lua | |
| parent | a65f3404028bd734e5deb793aa6b765c638a34db (diff) | |
reorg
Diffstat (limited to '.config/nvim/lua/plugins/treesitter.lua')
| -rw-r--r-- | .config/nvim/lua/plugins/treesitter.lua | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/.config/nvim/lua/plugins/treesitter.lua b/.config/nvim/lua/plugins/treesitter.lua new file mode 100644 index 0000000..268e13d --- /dev/null +++ b/.config/nvim/lua/plugins/treesitter.lua @@ -0,0 +1,24 @@ +return { + 'nvim-treesitter/nvim-treesitter', + ft = { 'c', 'cpp', 'zig', 'lua', 'rust' }, + build = ':TSUpdate', + config = function() + require('nvim-treesitter.configs').setup { + -- Add languages to be installed here that you want installed for treesitter + ensure_installed = { 'c', 'cpp', 'lua', 'rust', 'vimdoc', 'vim', 'zig' }, + + -- Install parsers synchronously (only applied to `ensure_installed`) + sync_install = false, + + -- Automatically install missing parsers when entering buffer + -- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally + auto_install = false, + + highlight = { + enable = true, + disable = function(_, bufnr) return vim.api.nvim_buf_line_count(bufnr) > 10000 end, + additional_vim_regex_highlighting = false, + }, + } + end, +} |
