diff --git a/.rubocop.yml b/.rubocop.yml index 8230cb9..7457108 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,4 +1,5 @@ AllCops: + NewCops: enable TargetRubyVersion: 2.7 Exclude: - _site/**/* @@ -7,7 +8,7 @@ AllCops: Metrics/BlockLength: Enabled: false -Metrics/LineLength: +Layout/LineLength: Enabled: false Metrics/MethodLength: diff --git a/spec/license_meta_spec.rb b/spec/license_meta_spec.rb index 3c65e39..858acfb 100644 --- a/spec/license_meta_spec.rb +++ b/spec/license_meta_spec.rb @@ -50,7 +50,7 @@ describe 'license meta' do let(:detected) { Licensee::ProjectFiles::LicenseFile.new(content, 'LICENSE').license } if example_url.start_with?('https://github.com/') - example_url.gsub!(%r{\Ahttps://github.com/([\w-]+/[\w\.-]+)/blob/(\S+)\z}, 'https://raw.githubusercontent.com/\1/\2') + example_url.gsub!(%r{\Ahttps://github.com/([\w-]+/[\w.-]+)/blob/(\S+)\z}, 'https://raw.githubusercontent.com/\1/\2') elsif example_url.start_with?('https://git.savannah.gnu.org/', 'https://git.gnome.org/') example_url.gsub!(%r{/tree/}, '/plain/') elsif example_url.start_with?('https://bitbucket.org/') diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index d66c491..60a2012 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -7,8 +7,8 @@ require 'open-uri' module SpecHelper class << self - attr_accessor :config, :licenses, :site, :spdx - attr_accessor :osi_approved_licenses, :fsf_approved_licenses, :od_approved_licenses + attr_accessor :config, :licenses, :site, :spdx, + :osi_approved_licenses, :fsf_approved_licenses, :od_approved_licenses end end