From 53ef5d112e622e23ef86478f9a5dddb3f10bf8a2 Mon Sep 17 00:00:00 2001 From: Kevin MacMartin Date: Fri, 1 Mar 2024 22:30:11 -0500 Subject: [PATCH] Use 4 spaces per tab in lua files --- vim/config/plugins/nvim-treesitter.lua | 38 ++++++++++++++------------ 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/vim/config/plugins/nvim-treesitter.lua b/vim/config/plugins/nvim-treesitter.lua index c398ec7..942a08b 100644 --- a/vim/config/plugins/nvim-treesitter.lua +++ b/vim/config/plugins/nvim-treesitter.lua @@ -1,22 +1,26 @@ -if (vim.g.enabletreesitter ~= nill and vim.g.enabletreesitter == 1) then - if (vim.g.treesitterparserdir ~= nill) then - local parser_dir = vim.g.treesitterparserdir - else - local parser_dir = "~/.config/nvim/treesitter-parsers" - end +if (vim.g.enabletreesitter ~= nill) then + if (vim.g.enabletreesitter == 1) then + local parser_dir - vim.opt.runtimepath:append(parser_dir) + if (vim.g.treesitterparserdir == nill) then + parser_dir = "~/.config/nvim/treesitter-parsers" + else + parser_dir = vim.g.treesitterparserdir + end - require'nvim-treesitter.configs'.setup { - ensure_installed = { "bash", "c", "cpp", "git_config", "html", "java", "javascript", "json", "lua", "php", "python", "query", "rust", "toml", "typescript", "vim", "vue" }, - sync_install = false, - auto_install = false, - parser_install_dir = parser_dir, + vim.opt.runtimepath:append(parser_dir) - highlight = { - enable = true, - disable = {}, - additional_vim_regex_highlighting = false, + require'nvim-treesitter.configs'.setup { + ensure_installed = { "bash", "c", "cpp", "git_config", "html", "java", "javascript", "json", "lua", "php", "python", "query", "rust", "toml", "typescript", "vim", "vue" }, + sync_install = false, + auto_install = false, + parser_install_dir = parser_dir, + + highlight = { + enable = true, + disable = {}, + additional_vim_regex_highlighting = false, + } } - } + end end