mirror of
https://github.com/He4eT/dotfiles.git
synced 2026-06-18 19:04:26 +00:00
nvim: treesitter: switch to main branch
This commit is contained in:
parent
b984b980b7
commit
92218358b2
1 changed files with 14 additions and 46 deletions
|
|
@ -546,55 +546,23 @@ require('lazy').setup({
|
||||||
--[[ cfg_lazy_treesitter: Highlight, edit, and navigate code ]]
|
--[[ cfg_lazy_treesitter: Highlight, edit, and navigate code ]]
|
||||||
{
|
{
|
||||||
'nvim-treesitter/nvim-treesitter',
|
'nvim-treesitter/nvim-treesitter',
|
||||||
dependencies = {
|
|
||||||
'nvim-treesitter/nvim-treesitter-textobjects',
|
|
||||||
},
|
|
||||||
build = ':TSUpdate',
|
build = ':TSUpdate',
|
||||||
config = function()
|
config = function()
|
||||||
require('nvim-treesitter.configs').setup {
|
require('nvim-treesitter').setup()
|
||||||
--[[ cfg_lazy_treesitter_langs ]]
|
--[[ cfg_lazy_treesitter_langs ]]
|
||||||
ensure_installed = {
|
local ensure_installed = {
|
||||||
'vim',
|
'vim',
|
||||||
'vimdoc',
|
'vimdoc',
|
||||||
'lua',
|
'lua',
|
||||||
'javascript',
|
'javascript',
|
||||||
'typescript',
|
'typescript',
|
||||||
'tsx',
|
'tsx',
|
||||||
'vue',
|
'vue',
|
||||||
'html',
|
'html',
|
||||||
'css',
|
'css',
|
||||||
'scss',
|
'scss',
|
||||||
},
|
|
||||||
auto_install = true,
|
|
||||||
highlight = { enable = true },
|
|
||||||
indent = { enable = true },
|
|
||||||
|
|
||||||
--[[ cfg_lazy_treesitter_keymaps ]]
|
|
||||||
|
|
||||||
incremental_selection = {
|
|
||||||
enable = true,
|
|
||||||
keymaps = {
|
|
||||||
init_selection = '<c-space>',
|
|
||||||
node_incremental = '<c-space>',
|
|
||||||
node_decremental = '<M-space>',
|
|
||||||
scope_incremental = '<c-s>',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
textobjects = {
|
|
||||||
select = {
|
|
||||||
enable = true,
|
|
||||||
lookahead = true,
|
|
||||||
keymaps = {
|
|
||||||
['aa'] = '@parameter.outer',
|
|
||||||
['ia'] = '@parameter.inner',
|
|
||||||
['af'] = '@function.outer',
|
|
||||||
['if'] = '@function.inner',
|
|
||||||
['ac'] = '@class.outer',
|
|
||||||
['ic'] = '@class.inner',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
require('nvim-treesitter').install(ensure_installed)
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
--[[ cfg_lazy_onedark: Colorscheme inspired by Atom ]]
|
--[[ cfg_lazy_onedark: Colorscheme inspired by Atom ]]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue