nvim: statusline: display function after filename
This commit is contained in:
parent
4a72940690
commit
4fb84796ca
|
@ -130,10 +130,6 @@ function M.lsp_status()
|
|||
end
|
||||
end
|
||||
|
||||
local current_function = vim.b.lsp_current_function
|
||||
if current_function and current_function ~= '' then
|
||||
status = status .. '(' .. current_function .. ')'
|
||||
end
|
||||
return status
|
||||
end
|
||||
|
||||
|
|
|
@ -80,7 +80,13 @@ require('lualine').setup({
|
|||
{ 'require("my.functions").lsp_status()', padding = 0 },
|
||||
{ 'diagnostics' }
|
||||
},
|
||||
lualine_c = { { 'filename', path = 1 } },
|
||||
lualine_c = { { 'filename', path = 1 }, { function()
|
||||
local curfun = vim.b.lsp_current_function
|
||||
if curfun and curfun ~= '' then
|
||||
return '(' .. curfun .. ')'
|
||||
end
|
||||
return ''
|
||||
end, padding = 0, color = 'StatusLineNC' } },
|
||||
lualine_x = { { 'filetype' } },
|
||||
lualine_y = { { 'progress' } },
|
||||
lualine_z = { { 'location' }, { '"🍄"', padding = 0 }
|
||||
|
|
Loading…
Reference in New Issue
Block a user