update telescope and treesitter for nvim v0.12
This commit is contained in:
@ -1,23 +1,18 @@
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
branch = "main", -- master is frozen; main required for nvim 0.12+
|
||||
event = { "BufReadPre", "BufNewFile" },
|
||||
build = ":TSUpdate",
|
||||
dependencies = {
|
||||
"windwp/nvim-ts-autotag",
|
||||
},
|
||||
config = function()
|
||||
local treesitter = require('nvim-treesitter.configs')
|
||||
|
||||
treesitter.setup({
|
||||
require('nvim-treesitter').setup({
|
||||
auto_install = true,
|
||||
sync_install = false,
|
||||
highlight = {
|
||||
enable = true,
|
||||
additional_vim_regex_highlighting = false,
|
||||
},
|
||||
prefer_git = true, -- tarball downloads fail for some parsers on 0.12
|
||||
highlight = { enable = true },
|
||||
indent = { enable = true },
|
||||
autotag = { enable = true },
|
||||
ensure_installed = {
|
||||
install = {
|
||||
'json',
|
||||
'javascript',
|
||||
'typescript',
|
||||
@ -35,17 +30,10 @@ return {
|
||||
'python',
|
||||
'gitignore',
|
||||
'c',
|
||||
},
|
||||
ignore_install = {},
|
||||
incremental_selection = {
|
||||
enable = true,
|
||||
keymaps = {
|
||||
init_selection = '<C-Space>',
|
||||
node_incremental = '<C-Space>',
|
||||
scope_incremental = false,
|
||||
node_decremental = '<bs>',
|
||||
},
|
||||
'mdx',
|
||||
},
|
||||
})
|
||||
|
||||
require('nvim-ts-autotag').setup()
|
||||
end,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user