Closed ashincoder closed 3 years ago
Heyyo @ashincoder, sorry for the inconvenience and late reply 😅 ,
As said in the cons
section of readme, this statusline doesn't come with lsp stuff by default.
But defaults.cool_symbol
and defaults.filename_section
can take custom modules. An easy way would be to define a function which returns a string, and pass it to the above said sections.
For Example,
function Lsp_stuff()
local get = vim.lsp.diagnostic.get_count
local signs =
" "..get(0, 'Error')..
" "..get(0, 'Warning')..
" "..get(0, 'Information')..
" " ..get(0, 'Hint')
return signs
end
And then pass it to, say defaults.filename_section
require'staline'.setup{
defaults = {
filename_section = "%{luaeval('Lsp_stuff()')}"
}
}
Which would look something like:
Yeah thanks.
It would be great if those were added. Right
You mean add inside the plugin?
Yeah
Oh, I think leaving this to the user would be better 😅.
Maybe I'll add this in beta branch.
yeah great
Hello I love the plugins of it's minimalism. If the lsp and treesitter things are added will add it to StarVim