From 256ba205e14b1c02fa5f1991a9760d445d7fcde4 Mon Sep 17 00:00:00 2001 From: siduck76 Date: Tue, 14 Sep 2021 09:31:48 +0530 Subject: [PATCH] rm un-needed separator from statusline --- lua/plugins/configs/statusline.lua | 31 +++++++++++------------------- 1 file changed, 11 insertions(+), 20 deletions(-) diff --git a/lua/plugins/configs/statusline.lua b/lua/plugins/configs/statusline.lua index 4e1010a..cd34bee 100644 --- a/lua/plugins/configs/statusline.lua +++ b/lua/plugins/configs/statusline.lua @@ -69,29 +69,20 @@ components.active[1][1] = { right_sep = { str = statusline_style.right, hl = { fg = colors.nord_blue, - bg = colors.one_bg2, + bg = colors.lightbg, } }, } components.active[1][2] = { - provider = statusline_style.right, - - hl = { - fg = colors.one_bg2, - bg = colors.lightbg, - }, -} - -components.active[1][3] = { provider = function() local filename = vim.fn.expand "%:t" local extension = vim.fn.expand "%:e" local icon = require("nvim-web-devicons").get_icon(filename, extension) if icon == nil then - icon = "" + icon = " " return icon end - return icon .. " " .. filename .. " " + return " " .. icon .. " " .. filename .. " " end, hl = { fg = colors.white, @@ -101,7 +92,7 @@ components.active[1][3] = { right_sep = { str = statusline_style.right, hl = { fg = colors.lightbg, bg = colors.lightbg2 } }, } -components.active[1][4] = { +components.active[1][3] = { provider = function() local dir_name = vim.fn.fnamemodify(vim.fn.getcwd(), ":t") return "  " .. dir_name .. " " @@ -117,7 +108,7 @@ components.active[1][4] = { } }, } -components.active[1][5] = { +components.active[1][4] = { provider = "git_diff_added", hl = { fg = colors.grey_fg2, @@ -126,7 +117,7 @@ components.active[1][5] = { icon = " ", } -- diffModfified -components.active[1][6] = { +components.active[1][5] = { provider = "git_diff_changed", hl = { fg = colors.grey_fg2, @@ -135,7 +126,7 @@ components.active[1][6] = { icon = "  ", } -- diffRemove -components.active[1][7] = { +components.active[1][6] = { provider = "git_diff_removed", hl = { fg = colors.grey_fg2, @@ -144,7 +135,7 @@ components.active[1][7] = { icon = "  ", } -components.active[1][8] = { +components.active[1][7] = { provider = "diagnostic_errors", enabled = function() return lsp.diagnostics_exist "Error" @@ -153,7 +144,7 @@ components.active[1][8] = { icon = "  ", } -components.active[1][9] = { +components.active[1][8] = { provider = "diagnostic_warnings", enabled = function() return lsp.diagnostics_exist "Warning" @@ -162,7 +153,7 @@ components.active[1][9] = { icon = "  ", } -components.active[1][10] = { +components.active[1][9] = { provider = "diagnostic_hints", enabled = function() return lsp.diagnostics_exist "Hint" @@ -171,7 +162,7 @@ components.active[1][10] = { icon = "  ", } -components.active[1][11] = { +components.active[1][10] = { provider = "diagnostic_info", enabled = function() return lsp.diagnostics_exist "Information"