changed treesitter

This commit is contained in:
pika 2024-06-25 11:25:08 +02:00
parent f309e61af6
commit 9523a0d8d6

View file

@ -1,16 +1,16 @@
return { return {
'nvim-treesitter/nvim-treesitter', "nvim-treesitter/nvim-treesitter",
event = { 'BufReadPre', 'BufNewFile' }, event = { "BufReadPre", "BufNewFile" },
build = ':TSUpdate', build = ":TSUpdate",
dependencies = { dependencies = {
'windwp/nvim-ts-autotag', "windwp/nvim-ts-autotag",
}, },
config = function() config = function()
-- import nvim-treesitter plugin -- import nvim-treesitter plugin
local treesitter = require 'nvim-treesitter.configs' local treesitter = require("nvim-treesitter.configs")
-- configure treesitter -- configure treesitter
treesitter.setup { -- enable syntax highlighting treesitter.setup({ -- enable syntax highlighting
highlight = { highlight = {
enable = true, enable = true,
}, },
@ -22,36 +22,44 @@ return {
}, },
-- ensure these language parsers are installed -- ensure these language parsers are installed
ensure_installed = { ensure_installed = {
'json', "bash",
'javascript', "fish",
'typescript', "http",
'tsx', "html",
'yaml', "php",
'html', "css",
'css', "scss",
'prisma', "gitignore",
'markdown', "git_config",
'markdown_inline', "markdown",
'svelte', "markdown_inline",
'graphql', "dockerfile",
'bash', "yaml",
'lua', "json",
'vim', "javascript",
'dockerfile', "typescript",
'gitignore', "tsx",
'query', "graphql",
'vimdoc', "lua",
'c', "query",
"c",
"prisma",
"svelte",
"hyprlang",
"ini",
"passwd",
"vim",
"vimdoc",
}, },
incremental_selection = { incremental_selection = {
enable = true, enable = true,
keymaps = { keymaps = {
init_selection = '<C-space>', init_selection = "<C-space>",
node_incremental = '<C-space>', node_incremental = "<C-space>",
scope_incremental = false, scope_incremental = false,
node_decremental = '<bs>', node_decremental = "<bs>",
}, },
}, },
} })
end, end,
} }