浏览代码

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

LostNeophyte 2 年之前
父节点
当前提交
d7a9e6244f
共有 1 个文件被更改,包括 3 次插入0 次删除
  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,
   },