tamton-aquib / staline.nvim

A modern lightweight statusline and bufferline plugin for neovim in lua.
MIT License
380 stars 17 forks source link

added support for expanding null-ls sources #32

Closed WilsonOh closed 2 years ago

WilsonOh commented 2 years ago

Hi everyone, I wanted to see the individual null-ls sources as part of the lsp_name section so I tried adding it in. The expansion can be activated by setting the expand_null_ls key to true in the defaults table during setup. i.e.

require('staline').setup {
  defaults = {
    expand_null_ls = true,
    ...
  }
}

With expand_null_ls set to true:

image image

With expand_null_ls set to false:

image

_The 'LSP: ' part is not part of the lspname section

It can be a bit messy if there are too many null-ls sources but I think it can be made better by filtering out the sources by their methods (diagnostics, formatting etc.).

What do you guys think?

tamton-aquib commented 2 years ago

Heyyo @WilsonOh , sorry for the late response.

Good catch on not adding the pcall 👍🏻 Also itd be better to send PRs to the dev branch (just in case 😅 ).

WilsonOh commented 2 years ago

Also itd be better to send PRs to the dev branch (just in case 😅 ).

Ah, sorry about that! I'll send a PR to the dev branch and close this one.