From 546752feb6576be92fe421be1998217aa7d657ff Mon Sep 17 00:00:00 2001 From: triethyl Date: Sun, 6 Jul 2025 22:21:45 -0400 Subject: working on nvim setup Former-commit-id: a43ab0499838d262445d8af9cb954a84e259bb35 --- pkgs/custom-neovim/config/lua/plugins/lualine.lua | 1 + 1 file changed, 1 insertion(+) create mode 100644 pkgs/custom-neovim/config/lua/plugins/lualine.lua (limited to 'pkgs/custom-neovim/config/lua/plugins/lualine.lua') diff --git a/pkgs/custom-neovim/config/lua/plugins/lualine.lua b/pkgs/custom-neovim/config/lua/plugins/lualine.lua new file mode 100644 index 0000000..9814cae --- /dev/null +++ b/pkgs/custom-neovim/config/lua/plugins/lualine.lua @@ -0,0 +1 @@ +require("lualine").setup() -- cgit v1.2.3 From be6c16189410b280dd9f94cc2821ffcbd721dbc2 Mon Sep 17 00:00:00 2001 From: triethyl Date: Mon, 7 Jul 2025 11:43:06 -0400 Subject: working on neovim Former-commit-id: 025d1930a0ae07909efe826cc902424ff57d5ce9 --- pkgs/custom-neovim/config/lua/plugins/lualine.lua | 99 ++++++++++++++++++++++- 1 file changed, 98 insertions(+), 1 deletion(-) (limited to 'pkgs/custom-neovim/config/lua/plugins/lualine.lua') diff --git a/pkgs/custom-neovim/config/lua/plugins/lualine.lua b/pkgs/custom-neovim/config/lua/plugins/lualine.lua index 9814cae..409c452 100644 --- a/pkgs/custom-neovim/config/lua/plugins/lualine.lua +++ b/pkgs/custom-neovim/config/lua/plugins/lualine.lua @@ -1 +1,98 @@ -require("lualine").setup() +local auto_theme = require("lualine.themes.auto") + +local colors = { + modes = { + normal = auto_theme.normal.a.bg, + insert = auto_theme.insert.a.bg, + visual = auto_theme.visual.a.bg, + replace = auto_theme.replace.a.bg, + command = auto_theme.command.a.bg, + inactive = auto_theme.inactive.a.bg, + }, + text = { + dark = auto_theme.normal.a.fg, + light = auto_theme.normal.c.fg, + }, + backdrop = auto_theme.normal.c.bg, +} + +local custom_auto_theme = { + normal = { + a = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, + }, + insert = { + a = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, + }, + visual = { + a = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, + }, + replace = { + a = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, + }, + command = { + a = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, + }, + inactive = { + a = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.backdrop, fg = colors.text.light}, + c = {bg = colors.backdrop, fg = colors.text.light}, + x = {bg = colors.backdrop, fg = colors.text.light}, + y = {bg = colors.backdrop, fg = colors.text.light}, + z = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, + }, +}; + +require('lualine').setup { + options = { + theme = custom_auto_theme, + component_separators = "", + section_separators = { left = '', right = '' }, + }, + sections = { + lualine_a = { { 'mode', separator = { left = '', rignt = '' }, right_padding = 2 } }, + lualine_b = { 'filename', 'branch' }, + lualine_c = { + '%=', --[[ add your center components here in place of this comment ]] + }, + lualine_x = {}, + lualine_y = { 'filetype', 'progress' }, + lualine_z = { + { 'location', separator = { left = '', right = '' }, left_padding = 2 }, + }, + }, + inactive_sections = { + lualine_a = { 'filename' }, + lualine_b = {}, + lualine_c = {}, + lualine_x = {}, + lualine_y = {}, + lualine_z = { 'location' }, + }, + tabline = {}, + extensions = {}, +} -- cgit v1.2.3 From a544c622d31187f245b34b9b8b17cbb63a941480 Mon Sep 17 00:00:00 2001 From: triethyl Date: Tue, 8 Jul 2025 15:44:17 -0400 Subject: configured lualine and tabby Former-commit-id: 947770af8ae586dfc89c0d498a766c7aaa802dd2 --- pkgs/custom-neovim/config/lua/plugins/lualine.lua | 154 ++++++++++------------ 1 file changed, 72 insertions(+), 82 deletions(-) (limited to 'pkgs/custom-neovim/config/lua/plugins/lualine.lua') diff --git a/pkgs/custom-neovim/config/lua/plugins/lualine.lua b/pkgs/custom-neovim/config/lua/plugins/lualine.lua index 409c452..b38d3ed 100644 --- a/pkgs/custom-neovim/config/lua/plugins/lualine.lua +++ b/pkgs/custom-neovim/config/lua/plugins/lualine.lua @@ -1,98 +1,88 @@ -local auto_theme = require("lualine.themes.auto") - -local colors = { - modes = { - normal = auto_theme.normal.a.bg, - insert = auto_theme.insert.a.bg, - visual = auto_theme.visual.a.bg, - replace = auto_theme.replace.a.bg, - command = auto_theme.command.a.bg, - inactive = auto_theme.inactive.a.bg, - }, - text = { - dark = auto_theme.normal.a.fg, - light = auto_theme.normal.c.fg, - }, - backdrop = auto_theme.normal.c.bg, -} - -local custom_auto_theme = { - normal = { - a = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, - }, - insert = { - a = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, - }, - visual = { - a = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, - }, - replace = { - a = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, - }, - command = { - a = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, - }, - inactive = { - a = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, - b = {bg = colors.backdrop, fg = colors.text.light}, - c = {bg = colors.backdrop, fg = colors.text.light}, - x = {bg = colors.backdrop, fg = colors.text.light}, - y = {bg = colors.backdrop, fg = colors.text.light}, - z = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, - }, -}; +local generate_lualine_theme = function() + local colors = utils.generate_theme_from_lualine() + return { + normal = { + a = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.normal, fg = colors.text.dark, gui = 'bold'}, + }, + insert = { + a = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.insert, fg = colors.text.dark, gui = 'bold'}, + }, + visual = { + a = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.visual, fg = colors.text.dark, gui = 'bold'}, + }, + replace = { + a = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.replace, fg = colors.text.dark, gui = 'bold'}, + }, + command = { + a = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.command, fg = colors.text.dark, gui = 'bold'}, + }, + inactive = { + a = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, + b = {bg = colors.background, fg = colors.text.light}, + c = {bg = colors.background, fg = colors.text.light}, + x = {bg = colors.background, fg = colors.text.light}, + y = {bg = colors.background, fg = colors.text.light}, + z = {bg = colors.modes.inactive, fg = colors.text.dark, gui = 'bold'}, + }, + }; +end require('lualine').setup { options = { - theme = custom_auto_theme, + theme = generate_lualine_theme(), component_separators = "", - section_separators = { left = '', right = '' }, + section_separators = { left = '', right = '' }, }, sections = { - lualine_a = { { 'mode', separator = { left = '', rignt = '' }, right_padding = 2 } }, - lualine_b = { 'filename', 'branch' }, - lualine_c = { - '%=', --[[ add your center components here in place of this comment ]] - }, - lualine_x = {}, - lualine_y = { 'filetype', 'progress' }, + lualine_a = { { 'mode', separator = { left = '', rignt = '' }, right_padding = 2 } }, -- { left = '', rignt = '' } + lualine_b = { 'filename', 'diff' }, + lualine_c = { 'branch' }, + lualine_x = { {'diagnostics', sources = { 'nvim_lsp' } } }, + lualine_y = { 'lsp_status', 'progress' }, lualine_z = { - { 'location', separator = { left = '', right = '' }, left_padding = 2 }, + { 'location', separator = { left = '', right = '' }, left_padding = 2 }, }, }, inactive_sections = { - lualine_a = { 'filename' }, - lualine_b = {}, + lualine_a = {}, + lualine_b = { 'filename' }, lualine_c = {}, lualine_x = {}, - lualine_y = {}, - lualine_z = { 'location' }, + lualine_y = { 'location' }, + lualine_z = {}, }, tabline = {}, extensions = {}, } + +-- vim.api.nvim_create_autocmd("ColorScheme", { +-- callback = function() +-- setup_lualine() +-- print "colorscheme changed" +-- end, +-- }) -- cgit v1.2.3