local default_theme = "base16-oceanicnext" local function get_tinty_theme() local theme_name = vim.fn.system( "tinty -d /home/lucy/.local/share/tinted-theming/tinty/ current &> /dev/null && tinty -d /home/lucy/.local/share/tinted-theming/tinty/ current" ) if vim.v.shell_error ~= 0 then return default_theme else return vim.trim(theme_name) end end local function handle_focus_gained() local new_theme_name = get_tinty_theme() local current_theme_name = vim.g.colors_name if current_theme_name ~= new_theme_name then vim.cmd("colorscheme " .. new_theme_name) end end local function main() vim.o.termguicolors = true vim.g.tinted_colorspace = 256 local current_theme_name = get_tinty_theme() vim.cmd("colorscheme " .. current_theme_name) vim.api.nvim_create_autocmd("FocusGained", { callback = handle_focus_gained, }) end return { { "RRethy/base16-nvim", lazy = false, init = function() main() end, }, { "nvim-lualine/lualine.nvim", dependencies = { "nvim-tree/nvim-web-devicons", "RRethy/base16-nvim" }, opts = { options = { component_separators = { left = "", right = "" }, section_separators = { left = "", right = "" }, }, sections = { lualine_a = { "mode" }, lualine_b = { "diagnostics" }, lualine_c = { "filename", "branch", "navic" }, lualine_x = { "lsp_status", "filetype" }, lualine_y = { "progress" }, lualine_z = { "location" }, }, }, }, { "nvimdev/lspsaga.nvim", dependencies = { "nvim-treesitter/nvim-treesitter", -- for syntax highlighting inside the popup "nvim-tree/nvim-web-devicons", -- for pretty icons }, opts = { symbol_in_winbar = { enable = true }, lightbulb = { enable = true, sign = false, }, hover = { max_width = 0.6, open_link = "gx", open_browser = "!google-chrome", }, }, }, { "akinsho/bufferline.nvim", opts = {}, }, }