From 4d497ec8a76d9ded8a99c0e33b51fd4e99974ee7 Mon Sep 17 00:00:00 2001 From: jdhao Date: Sun, 5 Dec 2021 14:59:08 +0800 Subject: update lualine conf --- lua/config/statusline.lua | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 lua/config/statusline.lua (limited to 'lua/config/statusline.lua') diff --git a/lua/config/statusline.lua b/lua/config/statusline.lua new file mode 100644 index 0000000..6b6dad7 --- /dev/null +++ b/lua/config/statusline.lua @@ -0,0 +1,37 @@ +local function spell() + if vim.o.spell then + return "[SPELL]" + end + + return "" +end + +require("lualine").setup({ + options = { + icons_enabled = true, + theme = "auto", + component_separators = { left = "", right = "" }, + section_separators = { left = "", right = "" }, + disabled_filetypes = {}, + always_divide_middle = true, + }, + sections = { + lualine_a = { "mode" }, + lualine_b = { "branch", "diff", }, + lualine_c = { spell, "filename" }, + lualine_x = { "encoding", "fileformat", "filetype" }, + lualine_y = { "progress" }, + lualine_z = { "location", { "diagnostics", sources = { "nvim_lsp" } }}, + }, + inactive_sections = { + lualine_a = {}, + lualine_b = {}, + lualine_c = { "filename" }, + lualine_x = { "location" }, + lualine_y = {}, + lualine_z = {}, + }, + tabline = {}, + extensions = {}, +}) + -- cgit v1.2.3