dotfiles/.config/nvim/lua/plugins/treesitter.lua
mitchell 0694ba3805 chore: update nvim plugins and switch python tooling to ruff
- bump ale, markview.nvim commits in lazy-lock
- replace pylint with ruff as python linter
- replace black with ruff/ruff_format as python formatter
- add java, kotlin, python to treesitter languages
2026-05-12 19:46:14 -04:00

51 lines
881 B
Lua

-- lua/plugins/treesitter.lua
return {
{
"nvim-treesitter/nvim-treesitter",
build = ":TSUpdate",
lazy = false,
init = function()
local langs = {
"c",
"lua",
"vim",
"vimdoc",
"query",
"markdown",
"markdown_inline",
"regex",
"bash",
"fish",
"typescript",
"javascript",
"tsx",
"svelte",
"go",
"elixir",
"vue",
"hcl",
"terraform",
"yaml",
"json",
"java",
"kotlin",
"python",
}
require("nvim-treesitter").install(langs)
vim.opt.foldexpr = "v:lua.vim.treesitter.foldexpr()"
vim.opt.foldmethod = "expr"
vim.opt.foldenable = false
table.insert(langs, "javascriptreact")
table.insert(langs, "typescriptreact")
vim.api.nvim_create_autocmd("FileType", {
pattern = langs,
callback = function()
vim.treesitter.start()
end,
})
end,
},
}