Add csv column to statusline

This commit is contained in:
ViViDboarder 2023-06-26 14:48:39 -07:00
parent 0d8261b924
commit 5c77243b8c
1 changed files with 11 additions and 1 deletions

View File

@ -35,6 +35,16 @@ function M.trailing_whitespace()
return ""
end
-- Plugin to print name of current CSV column
M.csv_col = {
function()
return vim.fn.CSVCol(1)
end,
cond = function()
return vim.bo.filetype == "csv" and vim.fn.exists("*CSVCol") == 1
end,
}
-- Configure lualine witha provided theme
function M.config_lualine(theme_name)
-- Theme name transformations
@ -102,7 +112,7 @@ function M.config_lualine(theme_name)
},
},
lualine_b = { "FugitiveHead", "diff" },
lualine_c = { { "filename", path = 1 }, code_loc },
lualine_c = { { "filename", path = 1 }, code_loc, M.csv_col },
lualine_x = { M.custom_ffenc, "filetype" },
lualine_y = { "progress", "location" },
lualine_z = {