Skip to content

Commit

Permalink
fix(install): dont load the colorscheme again if a config() of the …
Browse files Browse the repository at this point in the history
…colorscheme also loads it. Fixes #488
  • Loading branch information
folke committed Feb 7, 2023
1 parent 48c9b37 commit 49b43de
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lua/lazy/core/loader.lua
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ function M.install_missing()
for _, plugin in pairs(Config.plugins) do
if not (plugin._.installed or Plugin.has_errors(plugin)) then
for _, colorscheme in ipairs(Config.options.install.colorscheme) do
if pcall(vim.cmd.colorscheme, colorscheme) then
M.colorscheme(colorscheme)
if vim.g.colors_name or pcall(vim.cmd.colorscheme, colorscheme) then
break
end
end
Expand Down

0 comments on commit 49b43de

Please sign in to comment.