feat(vim): auto install treesitter grammars
Previously we were defining what ones we want to install. Now we are say we want to install the grammar when we go to a file. If we don't have that grammar installed then we will install it then
This commit is contained in:
parent
a1e089babb
commit
b1746b0178
1 changed files with 6 additions and 9 deletions
|
|
@ -1,4 +1,5 @@
|
||||||
require("nvim-treesitter.configs").setup {
|
require("nvim-treesitter.configs").setup {
|
||||||
|
auto_install = true,
|
||||||
playground = { enable = true },
|
playground = { enable = true },
|
||||||
indent = { enable = false },
|
indent = { enable = false },
|
||||||
rainbow = { enable = true },
|
rainbow = { enable = true },
|
||||||
|
|
@ -7,13 +8,9 @@ require("nvim-treesitter.configs").setup {
|
||||||
enable = true,
|
enable = true,
|
||||||
additional_vim_regex_highlighting = true,
|
additional_vim_regex_highlighting = true,
|
||||||
},
|
},
|
||||||
ensure_installed = {
|
|
||||||
"typescript",
|
|
||||||
"javascript",
|
|
||||||
"tsx",
|
|
||||||
"php",
|
|
||||||
"html",
|
|
||||||
"go",
|
|
||||||
"clojure",
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vim.opt.foldmethod = "expr"
|
||||||
|
vim.opt.foldexpr = "nvim_treesitter#foldexpr()"
|
||||||
|
vim.opt.foldenable = false
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue