From 8b01e3deadfc4e88dc948e8bb45cdd4caf64b771 Mon Sep 17 00:00:00 2001 From: Brandon Keepers Date: Fri, 16 Oct 2015 15:15:34 -0400 Subject: [PATCH 1/2] Upgrade to licensee 6.0.0b1 --- github-linguist.gemspec | 2 +- test/test_grammars.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/github-linguist.gemspec b/github-linguist.gemspec index bdba3e6b25..cdfc6bef83 100644 --- a/github-linguist.gemspec +++ b/github-linguist.gemspec @@ -24,6 +24,6 @@ Gem::Specification.new do |s| s.add_development_dependency 'rake' s.add_development_dependency 'yajl-ruby' s.add_development_dependency 'color-proximity', '~> 0.2.1' - s.add_development_dependency 'licensee', '~> 4.7.4' + s.add_development_dependency 'licensee', '6.0.0b1' end diff --git a/test/test_grammars.rb b/test/test_grammars.rb index 569da5c953..e7afd8e262 100644 --- a/test/test_grammars.rb +++ b/test/test_grammars.rb @@ -81,7 +81,7 @@ def test_local_scopes_are_in_sync end def test_submodules_have_recognized_licenses - unrecognized = submodule_licenses.select { |k,v| v.nil? && Licensee::Project.new(k).license_file } + unrecognized = submodule_licenses.select { |k,v| v.nil? && Licensee::FSProject.new(k).license_file } unrecognized.reject! { |k,v| PROJECT_WHITELIST.include?(k) } message = "The following submodules have unrecognized licenses:\n* #{unrecognized.keys.join("\n* ")}\n" message << "Please ensure that the project's LICENSE file contains the full text of the license." @@ -132,7 +132,7 @@ def submodule_licenses # Given the path to a submodule, return its SPDX-compliant license key def submodule_license(submodule) # Prefer Licensee to detect a submodule's license - project = Licensee::Project.new(submodule) + project = Licensee::FSProject.new(submodule) return project.license.key if project.license # We know a license file exists, but Licensee wasn't able to detect the license, From 9d865ec0182de14df01ef37fe662d81df9217633 Mon Sep 17 00:00:00 2001 From: Brandon Keepers Date: Fri, 16 Oct 2015 15:16:04 -0400 Subject: [PATCH 2/2] license of factor grammar is now detected properly --- test/test_grammars.rb | 1 - 1 file changed, 1 deletion(-) diff --git a/test/test_grammars.rb b/test/test_grammars.rb index e7afd8e262..a2ad1e5332 100644 --- a/test/test_grammars.rb +++ b/test/test_grammars.rb @@ -9,7 +9,6 @@ class TestGrammars < Minitest::Test # This grammar has a nonstandard but acceptable license. "vendor/grammars/gap-tmbundle", - "vendor/grammars/factor", # These grammars have no license but have been grandfathered in. New grammars # must have a license that allows redistribution.