diff options
| author | moxie <moxie.git@posteo.net> | 2025-09-30 12:27:44 +0300 |
|---|---|---|
| committer | moxie <moxie.git@posteo.net> | 2025-09-30 12:27:44 +0300 |
| commit | 1e27d1c7b25e4d28a25c0fa2c4e6e33a66b9072e (patch) | |
| tree | 7169509b4d5dfce3ed25fe333cc506a40f5c90f2 /.config/nvim/lua/plugins/lualine.lua | |
| parent | 51797f743fe74d1723ca62085f92e8c5e953038b (diff) | |
add nvim configs
Diffstat (limited to '.config/nvim/lua/plugins/lualine.lua')
| -rw-r--r-- | .config/nvim/lua/plugins/lualine.lua | 161 |
1 files changed, 161 insertions, 0 deletions
diff --git a/.config/nvim/lua/plugins/lualine.lua b/.config/nvim/lua/plugins/lualine.lua new file mode 100644 index 0000000..c1000ef --- /dev/null +++ b/.config/nvim/lua/plugins/lualine.lua @@ -0,0 +1,161 @@ +return { + "nvim-lualine/lualine.nvim", + dependencies = { "nvim-tree/nvim-web-devicons" }, + + config = function() + local theme = function() + local colors = { + black = '#282828', + black_hard = '#1d2021', + white = '#ebdbb2', + red = '#fb4934', + green = '#b8bb26', + yellow = '#d79921', + yellow_bright = '#fabd2f', + blue = '#83a598', + purple = '#d3859b', + aqua = '#8ec07c', + orange = '#d65d0e', + orange_bright = '#fe8019', + gray = '#a89984', + darkgray = '#3c3836', + lightgray = '#504945', + inactivegray = '#7c6f64', + } + + return { + normal = { + a = { bg = colors.yellow, fg = colors.black, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + insert = { + a = { bg = colors.yellow, fg = colors.black, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + visual = { + a = { bg = colors.yellow, fg = colors.black, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + replace = { + a = { bg = colors.yellow, fg = colors.black, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + command = { + a = { bg = colors.yellow, fg = colors.black, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + inactive = { + a = { bg = colors.darkgray, fg = colors.gray, gui = 'bold' }, + b = { bg = colors.darkgray, fg = colors.gray }, + c = { bg = colors.darkgray, fg = colors.gray } + } + } + end + + + local tty = function() + local colors = { + black = '#000000', + -- white = '#ffffff', + white = '#ebdbb2', + yellow = '#d79921', + gray = '#a89984', + darkgray = '#3c3836', + } + + return { + normal = { + a = { bg = colors.yellow, fg = colors.black }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + insert = { + a = { bg = colors.yellow, fg = colors.black }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + visual = { + a = { bg = colors.yellow, fg = colors.black }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + replace = { + a = { bg = colors.yellow, fg = colors.black }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + command = { + a = { bg = colors.yellow, fg = colors.black }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + }, + inactive = { + a = { bg = colors.darkgray, fg = colors.white }, + b = { bg = colors.darkgray, fg = colors.white }, + c = { bg = colors.darkgray, fg = colors.white } + } + } + end + + require('lualine').setup { + options = { + icons_enabled = false, + theme = theme, -- theme or tty + component_separators = { left = '', right = '' }, + section_separators = { left = '', right = '' }, + disabled_filetypes = { + statusline = {}, + winbar = {}, + }, + ignore_focus = {}, + always_divide_middle = true, + always_show_tabline = true, + globalstatus = false, + refresh = { + statusline = 1000, + tabline = 1000, + winbar = 1000, + refresh_time = 16, + events = { + 'WinEnter', + 'BufEnter', + 'BufWritePost', + 'SessionLoadPost', + 'FileChangedShellPost', + 'VimResized', + 'Filetype', + 'CursorMoved', + 'CursorMovedI', + 'ModeChanged', + }, + } + }, + sections = { + lualine_a = { 'mode' }, + lualine_b = { 'branch', 'diff', 'diagnostics' }, + lualine_c = { 'filename' }, + lualine_x = { 'encoding', 'fileformat', 'filetype' }, + -- lualine_y = { 'progress' }, + lualine_y = { '' }, + lualine_z = { 'location' } + }, + inactive_sections = { + lualine_a = {}, + lualine_b = {}, + lualine_c = { 'filename' }, + lualine_x = { 'location' }, + lualine_y = {}, + lualine_z = {} + }, + tabline = {}, + winbar = {}, + inactive_winbar = {}, + extensions = {} + } + end, +} |
