Simplify light mode toggle with a switch

This commit is contained in:
Alex Selimov 2025-09-11 10:18:07 -04:00
parent c34dee4d4e
commit 84e339864c
No known key found for this signature in database
GPG key ID: BC03C17FF5CFFFD2
2 changed files with 7 additions and 5 deletions

View file

@ -1,3 +1,6 @@
-- set to true for light mode
vim.g.light_mode = true
-- Neovim configuration
-- Modularized structure for better organization

View file

@ -7,11 +7,10 @@ return {
priority = 1000,
dependencies = "rktjmp/lush.nvim",
config = function()
vim.cmd.colorscheme("zenwritten")
local term_bg = os.getenv("TERM_BACKGROUND")
if term_bg == "light" then
vim.opt.background = "light"
if vim.g.light_mode then
vim.o.background = "light"
end
vim.cmd.colorscheme("zenbones")
end,
},