add hot reloading of lua line when switching theme

This commit is contained in:
lucy 2026-03-30 13:16:37 +02:00
commit 56e7410d61
3 changed files with 11 additions and 4 deletions

View file

@ -25,7 +25,7 @@ require("config.keymaps")
local default_theme = "base16-oceanicnext"
local function get_tinty_theme()
local theme_name = vim.fn.system("cat ~/.local/share/tinted-theming/tinty/current_scheme")
local theme_name = vim.fn.system("cat ~/.local/share/tinted-theming/tinty/current_scheme")
if vim.v.shell_error ~= 0 then
return default_theme
@ -40,7 +40,9 @@ local function handle_focus_gained()
if current_theme_name ~= new_theme_name then
vim.cmd("colorscheme " .. new_theme_name)
require("lualine").setup()
end
require("lualine").setup()
end
local function main()