aboutsummaryrefslogtreecommitdiff
path: root/lua/plugins/treesitter.lua
blob: cdf9800151f5d9c369b5f4abdad7a13096d27f69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
vim.pack.add({
  { src = "https://github.com/nvim-treesitter/nvim-treesitter" },
})
---@diagnostic disable: missing-fields
require("nvim-treesitter.configs").setup({
  ensure_installed = { "go", "nix" },

  auto_install = true,

  highlight = {
    enable = true,
  },

  incremental_selection = {
    enable = true,
    keymaps = {
      init_selection = "<Leader>ss",
      node_incremental = "<Leader>si",
      scope_incremental = "<Leader>sc",
      node_decremental = "<Leader>sd",
    },
  },
})