From 8babf12991a2baaf6178f56467dfc6b141f4b846 Mon Sep 17 00:00:00 2001 From: siduck Date: Sat, 17 Dec 2022 17:04:52 +0530 Subject: [PATCH] avoid swallowing custom/init.lua errors by pcall --- init.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/init.lua b/init.lua index a0d3b24..3ee09a5 100644 --- a/init.lua +++ b/init.lua @@ -41,6 +41,10 @@ if fn.empty(fn.glob(install_path)) > 0 then }) end -pcall(require, "custom") +local custom_init_path = vim.api.nvim_get_runtime_file("lua/custom/init.lua", false)[1] + +if custom_init_path then + dofile(custom_init_path) +end require("core.utils").load_mappings()