nvim/lua/cosmic/init.lua
2022-02-06 19:01:26 -08:00

16 lines
410 B
Lua

local mods = {
'cosmic.compiled',
'cosmic.core',
'cosmic.theme',
}
for _, mod in ipairs(mods) do
local ok, err = pcall(require, mod)
if mod == 'cosmic.compiled' and not ok then
vim.notify('Run :PackerCompile!', vim.log.levels.WARN, {
title = 'CosmicNvim',
})
elseif not ok and not mod:find('cosmic.core.user') then
error(('Error loading %s...\n\n%s'):format(mod, err))
end
end