[neovim] add nvim-treesitter
This commit is contained in:
parent
a10a792da6
commit
053d1f905e
@ -68,6 +68,7 @@
|
|||||||
vim.opt.smartindent = true
|
vim.opt.smartindent = true
|
||||||
|
|
||||||
-- load plugins
|
-- load plugins
|
||||||
|
-- neo-tree
|
||||||
require("neo-tree").setup({
|
require("neo-tree").setup({
|
||||||
filesystem = {
|
filesystem = {
|
||||||
filtered_items = {
|
filtered_items = {
|
||||||
@ -82,6 +83,21 @@
|
|||||||
})
|
})
|
||||||
require("neo-tree.sources.manager").show("filesystem")
|
require("neo-tree.sources.manager").show("filesystem")
|
||||||
|
|
||||||
|
-- nvim-treesitter
|
||||||
|
require("nvim-treesitter").setup({
|
||||||
|
build = ":TSUpdate",
|
||||||
|
config = function ()
|
||||||
|
local configs = require("nvim-treesitter.configs")
|
||||||
|
configs.setup({
|
||||||
|
ensure_installed = { "ansible", "css", "lua", "nix,", "yaml" },
|
||||||
|
sync_install = false,
|
||||||
|
highlight = { enable = true },
|
||||||
|
indent = { enable = true },
|
||||||
|
})
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
-- function for new line
|
-- function for new line
|
||||||
_G.add_new_line = function()
|
_G.add_new_line = function()
|
||||||
local n_lines = vim.api.nvim_buf_line_count(0)
|
local n_lines = vim.api.nvim_buf_line_count(0)
|
||||||
@ -115,6 +131,7 @@
|
|||||||
# plugins
|
# plugins
|
||||||
plugins = with pkgs.vimPlugins; [
|
plugins = with pkgs.vimPlugins; [
|
||||||
neo-tree-nvim
|
neo-tree-nvim
|
||||||
|
nvim-treesitter
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user