From 6b27c39f5da675f779eacaf4231f769357867d50 Mon Sep 17 00:00:00 2001 From: punkfairie Date: Wed, 27 Nov 2024 20:28:15 -0800 Subject: [PATCH] WIP: lualine --- .../plugins/ui/lualine.nvim/default.nix | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 modules/nixvim/plugins/ui/lualine.nvim/default.nix diff --git a/modules/nixvim/plugins/ui/lualine.nvim/default.nix b/modules/nixvim/plugins/ui/lualine.nvim/default.nix new file mode 100644 index 0000000..04ee7ac --- /dev/null +++ b/modules/nixvim/plugins/ui/lualine.nvim/default.nix @@ -0,0 +1,36 @@ +_: { + plugins.lualine = { + enable = true; + + luaConfig.pre.__raw = '' + vim.g.lualine_laststatus = vim.o.laststatus + if vim.fn.argc(-1) > 0 then + -- set an empty statusline till lualine loads + vim.o.statusline = " " + else + -- hide the statusline on the starter page + vim.o.laststatus = 0 + end + ''; + + settings = { + options = { + theme = "auto"; + globalstatus.__raw = "vim.o.laststatus == 3"; + disabled_filetypes.statusline = [ + "dashboard" + "alpha" + "ministarter" + "snacks_dashboard" + ]; + }; + sections = { + lualine_a = ["mode"]; + lualine_b = ["branch"]; + + lualine_c = [ + ]; + }; + }; + }; +}