class Licensee::Matchers::Gemspec

Constants

LICENSE_REGEX

We definitely don't want to be evaling arbitrary Gemspec files While not 100% accurate, use some lenient regex to try to grep the license declaration from the Gemspec as a string, if any

Private Instance Methods

license_property() click to toggle source
# File lib/licensee/matchers/gemspec_matcher.rb, line 13
def license_property
  match = @file.content.match LICENSE_REGEX
  match[1].downcase if match && match[1]
end