Sha256: f9c0849f2f933d89e2727bd1ac8f4b5005e8a110d6934b9a90514ebe0c3a14ea
Contents?: true
Size: 441 Bytes
Versions: 21
Compression:
Stored size: 441 Bytes
Contents
module Licensee module Matchers class Cabal < Licensee::Matchers::Package # While we could parse the cabal file, prefer # a lenient regex for speed and security. Moar parsing moar problems. LICENSE_REGEX = /^\s*license\s*\:\s*([a-z\-0-9\.]+)\s*$/ix private def license_property match = @file.content.match LICENSE_REGEX match[1].downcase if match && match[1] end end end end
Version data entries
21 entries across 21 versions & 1 rubygems