Add treesitter

This commit is contained in:
2026-01-14 21:01:46 +01:00
parent 6ce99540d1
commit 3edbe2c7f3
5 changed files with 38 additions and 10 deletions

View File

@ -17,14 +17,10 @@ end
vim.opt.rtp:prepend(lazypath)
-- Initialize lazy.nvim
require("lazy").setup({
{
"folke/tokyonight.nvim",
lazy = false, -- load immediately
priority = 1000, -- load before other plugins
config = function()
vim.cmd("colorscheme tokyonight")
end,
},
})
local plugins = {
require("plugins.tokyonight"), -- theme
require("plugins.treesitter"), -- syntax tree
}
require("lazy").setup(plugins)

11
lua/config/treesitter.lua Normal file
View File

@ -0,0 +1,11 @@
return {
"nvim-treesitter/nvim-treesitter",
run = ":TSUpdate",
config = function()
require("nvim-treesitter.configs").setup({
ensure_installed = { "lua", "c", "cpp", "rust" },
highlight = { enable = true, additional_vim_regex_highlighting = false },
indent = { enable = true },
})
end,
}