Class: LicenseFinder::SbtPackage
- Defined in:
- lib/license_finder/packages/sbt_package.rb
Instance Attribute Summary
Attributes inherited from Package
#authors, #children, #description, #groups, #homepage, #install_path, #license_names_from_spec, #logger, #manual_approval, #name, #package_url, #parents, #summary, #version
Instance Method Summary collapse
-
#initialize(spec, options = {}) ⇒ SbtPackage
constructor
A new instance of SbtPackage.
- #package_manager ⇒ Object
Methods inherited from Package
#<=>, #activations, #approved?, #approved_manually!, #approved_manually?, #decide_on_license, #eql?, #hash, #license_files, license_names_from_standard_spec, #licenses, #licenses_from_spec, #licensing, #log_activation, #missing?, #notice_files, #permitted!, #permitted?, #restricted!, #restricted?
Constructor Details
#initialize(spec, options = {}) ⇒ SbtPackage
5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/license_finder/packages/sbt_package.rb', line 5 def initialize(spec, = {}) name = spec['artifactId'] name = "#{spec['groupId']}:#{name}" if [:include_groups] super( name, spec['version'], .merge( spec_licenses: Array(spec['licenses']).map { |l| l['name'] } ) ) end |
Instance Method Details
#package_manager ⇒ Object
18 19 20 |
# File 'lib/license_finder/packages/sbt_package.rb', line 18 def package_manager 'Sbt' end |