module Thanks

Let's thank people for making the Ruby code we depend on!

Constants

VERSION

Public Class Methods

bundled_gems() click to toggle source
# File lib/thanks.rb, line 34
def self.bundled_gems
  @_bundled_gems ||= `bundle list`
                     .split("\n")
                     .drop(1).map(&:split)
                     .map { |words| words.drop(1) }
                     .map(&:first)
end
matches() click to toggle source
# File lib/thanks.rb, line 21
def self.matches
  registry = Registry.new.fetch

  @_matches ||= registry.select do |name, _url|
    system_gems.include?(name) ||
      bundled_gems.include?(name)
  end
end
print_list() click to toggle source
system_gems() click to toggle source
# File lib/thanks.rb, line 30
def self.system_gems
  @_system_gems ||= `gem list`.split("\n").map(&:split).map(&:first)
end