Add treesitter
This commit is contained in:
@ -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
11
lua/config/treesitter.lua
Normal 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,
|
||||
}
|
||||
Reference in New Issue
Block a user