Merge pull request #37 from prertik/nvim-switch-to-current-theme

Be able to switch to current theme for neovim
This commit is contained in:
David Heinemeier Hansson
2025-07-04 11:42:44 -07:00
committed by GitHub

View File

@ -1,4 +1,8 @@
return {
local uv = vim.uv
local file_path = vim.fn.expand("~/.config/omarchy/current/theme/neovim.lua")
-- Default configuration
local default = {
{
"LazyVim/LazyVim",
opts = {
@ -6,3 +10,13 @@ return {
},
},
}
-- Try to load custom theme, fallback to default
if uv.fs_stat(file_path) then
local success, result = pcall(dofile, file_path)
if success and type(result) == "table" then
return result
end
end
return default