local ts_langs = { "bash", "cpp", "fennel", "fish", "go", "haskell", "html", "java", "javascript", "jsdoc", "json", "markdown", "nix", "python", "query", "racket", "rust", "scheme", "teal", "toml", "tsx", "typescript", "verilog" }

require'nvim-treesitter.install'.compilers = { "gcc" }
require'nvim-treesitter.configs'.setup {
  ensure_installed = ts_langs,
  highlight        = { enable = true, },
  query_linter = {
    enable           = true,
    use_virtual_text = true,
    lint_events      = { "BufWrite", "CursorHold" },
  },
  matchup = {
    enable = true,
  },
}

vim.keymap.set('o', '<Leader>m', ':<C-U>lua require(\'tsht\').nodes()<CR>', { noremap=false, unique=true, silent=true })
vim.keymap.set('x', '<Leader>m', ':lua require(\'tsht\').nodes()<CR>' , { noremap=true , unique=true, silent=true })
