From 85c716be5e32a6f9c480ad3f58c7b70221582923 Mon Sep 17 00:00:00 2001 From: jgmdev Date: Wed, 1 Jun 2022 23:01:12 -0400 Subject: fix wrong loading order of user enabled plugins --- plugins/settings.lua | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/plugins/settings.lua b/plugins/settings.lua index bffb697..461463b 100644 --- a/plugins/settings.lua +++ b/plugins/settings.lua @@ -1411,15 +1411,6 @@ local core_run = core.run function core.run() store_default_keybindings() - -- append all settings defined in the plugins spec - scan_plugins_spec() - - -- merge custom settings into config - merge_settings() - - ---@type settings.ui - settings.ui = Settings() - -- load plugins disabled by default and enabled by user if settings.config.enabled_plugins then for name, _ in pairs(settings.config.enabled_plugins) do @@ -1428,11 +1419,20 @@ function core.run() and not config.plugins[name] then - settings.ui:enable_plugin(name) + require("plugins." .. name) end end end + -- append all settings defined in the plugins spec + scan_plugins_spec() + + -- merge custom settings into config + merge_settings() + + ---@type settings.ui + settings.ui = Settings() + -- apply user chosen color theme if settings.config.theme then core.reload_module("colors." .. settings.config.theme) -- cgit v1.2.3