From 9f20c1f313e20102dd83adeaf091284be1fd82d0 Mon Sep 17 00:00:00 2001 From: "eric.marin" Date: Wed, 11 Sep 2024 14:49:39 +0200 Subject: config --- nvim/lua/plugins/nvim-treesitter.lua | 47 ++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 nvim/lua/plugins/nvim-treesitter.lua (limited to 'nvim/lua/plugins/nvim-treesitter.lua') diff --git a/nvim/lua/plugins/nvim-treesitter.lua b/nvim/lua/plugins/nvim-treesitter.lua new file mode 100644 index 0000000..988673b --- /dev/null +++ b/nvim/lua/plugins/nvim-treesitter.lua @@ -0,0 +1,47 @@ +local config = function() + require("nvim-treesitter.configs").setup({ + ensure_installed = { + "c", + "lua", + "markdown", + "vim", + "vimdoc", + "query", + + "regex", + "diff", + "cmake", + "markdown_inline", + "bash", + "toml", + + "cpp", + "rust", + "haskell", + "nix" + }, + auto_install = false, + highlight = { + enable = true, + additional_vim_regex_highlighting = false, + }, + incremental_selection = { + enable = true + }, + indent = { + enable = true, + }, + autotag = { + enable = true, + }, + }) + + vim.cmd(":TSUpdate") +end + +return { + "nvim-treesitter/nvim-treesitter", + lazy = true, + event = { "BufReadPost", "BufWritePost", "BufNewFile" }, + config = config, +} -- cgit v1.2.3