From 2a32303bd67b84d7401beeeaf35658aab2ce0e78 Mon Sep 17 00:00:00 2001 From: Leon Connor Holm Date: Mon, 21 Aug 2023 09:34:36 +0200 Subject: [PATCH] feat(#7): implemented rtp init --- init.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/init.lua b/init.lua index cec8193..246a7f7 100644 --- a/init.lua +++ b/init.lua @@ -1,3 +1,13 @@ +local base_dir = vim.env.QUANTUMVIM_RTP_DIR + or (function() + local init_path = debug.getinfo(1, "S").source + return init_path:sub(2):match("(.*[/\\])"):sub(1, -2) + end)() + +if not vim.tbl_contains(vim.opt.rtp:get(), base_dir) then + vim.opt.rtp:prepend(base_dir) +end + vim.loader.enable() require("qvim.bootstrap"):init()