galaxyline.nvim icon indicating copy to clipboard operation
galaxyline.nvim copied to clipboard

Additional providers

Open ranebrown opened this issue 4 years ago • 5 comments
trafficstars

Would you be interested in starting a wiki page or some sort of additional readme in a docs folder with other providers that people can easily grab and use?

For example, here is a simple trailing whitespace function

local function trailing_whitespace()
    local trail = vim.fn.search("\\s$", "nw")
    if trail ~= 0 then
        return " "
    else
        return nil
    end
end

ranebrown avatar Nov 26 '20 18:11 ranebrown

I'd like this too! It'd be easier than searching dotfiles for ideas 😁

Iron-E avatar Nov 27 '20 05:11 Iron-E

In order to share the statusline created by everyone, I opened issue #12, just to share a custom provider, is the wiki page a good choice? If there are many providers, the page will look very long. Maybe it would be better to add some categories

glepnir avatar Nov 27 '20 06:11 glepnir

#12 seems like a good fit. Like you said in the OP of that issue, links to the source of each submission are needed (if we want to cover the use case of a wiki)

Iron-E avatar Nov 27 '20 15:11 Iron-E

Seems like trying to store them all in an issue would get pretty cumbersome quickly and make it hard to find anything. Somehow sorting them by categories is a good idea.

ranebrown avatar Nov 28 '20 22:11 ranebrown

What about a completely separate contrib repository? Separate providers by folder, license it so that anyone can either grab code from the repo or install it as a plugin.

That would keep the number of providers down in this repo, while still allowing easy installation of additional sources. I know snippet plugins take this approach too

Iron-E avatar Nov 29 '20 00:11 Iron-E