From 88bd63d4077e3ef136bceed7f1b9eba5801b27e4 Mon Sep 17 00:00:00 2001 From: siduck Date: Fri, 3 Jun 2022 01:08:09 +0530 Subject: [PATCH] fix #1168 | make disabling of default plugins in options.lua overridable --- lua/core/options.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lua/core/options.lua b/lua/core/options.lua index 168a357..4b2fb17 100644 --- a/lua/core/options.lua +++ b/lua/core/options.lua @@ -79,10 +79,14 @@ local default_plugins = { "zipPlugin", } +local overridden_opts = config.options.disable_default_plugins +default_plugins = vim.tbl_deep_extend("force", default_plugins, overridden_opts or default_plugins) + for _, plugin in pairs(default_plugins) do g["loaded_" .. plugin] = 1 end +-- set shada path vim.schedule(function() vim.opt.shadafile = vim.fn.expand "$HOME" .. "/.local/share/nvim/shada/main.shada" vim.cmd [[ silent! rsh ]]