Adding Needs Funding to Your Ruby Gem

In a recent Bundler blog post: Bundler: Bundler v2.2: Multiplatform, Funding, and more. I discovered that they announced a new funding feature:

Find out about gems you depend on that need funding

We really want to help building a more sustainable ruby ecosystem, so we’re shipping a new bundle fund command that helps you discovering the libraries you depend on that need funding.

If you develop a gem that needs funding, make sure you fill in the funding_uri metadata in your gemspec, like this:

Gem::Specification.new do |gem|
  gem.name = "#{GEM_NAME}"
  gem.homepage = "#{GEM_HOMEPAGE}"
  s.metadata = {
    "funding_uri" => "#{GEM_FUNDING_PAGE}"
  }
end

As soon as people start filling this metadata, bundle fund will start reporting all of your dependencies that need funding.

I think with the addition of GitHub Sponsors, this new funding feature, and the overall habit we are all getting into paying for monthly services, we are about to enter into a new era of open sources projects and developers actually earning decent money. At least I hope so anyways.

And a reminder if your company relies on an open source project, try to donate some money to them. Even as individuals, if there is a project that you love I think we can all afford a few dollars to show our support. I’m sure it will go a long way.