Browse Source

fix(treesitter): prepend to rtp (#3708)

LostNeophyte 2 years ago
parent
commit
d7a9e6244f
1 changed files with 3 additions and 0 deletions
  1. 3 0
      lua/lvim/plugins.lua

+ 3 - 0
lua/lvim/plugins.lua

@@ -102,6 +102,9 @@ local core_plugins = {
     "nvim-treesitter/nvim-treesitter",
     -- run = ":TSUpdate",
     config = function()
+      local utils = require "lvim.utils"
+      local path = utils.join_paths(get_runtime_dir(), "site", "pack", "lazy", "opt", "nvim-treesitter")
+      vim.opt.rtp:prepend(path) -- treesitter needs to be before nvim's runtime in rtp
       require("lvim.core.treesitter").setup()
     end,
   },