From ed18649e94b58a2855d43e9356c56433d207f683 Mon Sep 17 00:00:00 2001 From: siduck Date: Mon, 9 Oct 2023 17:13:11 +0530 Subject: [PATCH] statusline: dont reload if theme is custom this will prevent auto-reload of statusline , good for non custom statusline users --- lua/core/init.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lua/core/init.lua b/lua/core/init.lua index 19804e17..6f396aca 100644 --- a/lua/core/init.lua +++ b/lua/core/init.lua @@ -93,8 +93,10 @@ autocmd("BufWritePost", { vim.g.transparency = config.ui.transparency -- statusline - require("plenary.reload").reload_module("nvchad.statusline." .. config.ui.statusline.theme) - vim.opt.statusline = "%!v:lua.require('nvchad.statusline." .. config.ui.statusline.theme .. "').run()" + if config.ui.statusline.theme ~= "custom" then + require("plenary.reload").reload_module("nvchad.statusline." .. config.ui.statusline.theme) + vim.opt.statusline = "%!v:lua.require('nvchad.statusline." .. config.ui.statusline.theme .. "').run()" + end -- tabufline if config.ui.tabufline.enabled then