1
0
Fork 0

lualine: don't show encoding and format for good defaults (utf-8/unix)

and show relative directory in the filename
This commit is contained in:
Felipe 2023-06-29 22:34:45 -04:00
parent 9f96f26128
commit 7d10a43ad0
Signed by: pitbuster
SSH key fingerprint: SHA256:HDYu2Pm4/TmSX8GBwV49UvFWr1Ljg8XlHxKeCpjJpOk

View file

@ -59,12 +59,36 @@ lualine.setup({
sections = {
lualine_a = { 'mode' },
lualine_b = { 'diagnostics' },
lualine_c = { 'filename' },
lualine_x = { 'fileformat', 'encoding' },
lualine_c = {
{
'filename',
path = 1,
},
},
lualine_x = {
{
'fileformat',
cond = function()
return vim.bo.fileformat ~= 'unix'
end,
},
{
'encoding',
cond = function()
return vim.bo.fileencoding ~= 'utf-8'
end,
},
},
lualine_y = {
{
'filetype',
icons_enabled = false,
symbols = {
modified = '',
readonly = '',
unnamed = '',
new = '󰎔',
},
}
},
lualine_z = { 'searchcount', 'progress', 'location' },