ruby-changes:62233
From: Utkarsh <ko1@a...>
Date: Wed, 15 Jul 2020 16:05:48 +0900 (JST)
Subject: [ruby-changes:62233] d0810fdee4 (master): [rubygems/rubygems] Use latest version of rubocop for RUBY_VERSION > 2.4
https://git.ruby-lang.org/ruby.git/commit/?id=d0810fdee4 From d0810fdee453fef24492dcfdb0876d57f3b90d6a Mon Sep 17 00:00:00 2001 From: Utkarsh Gupta <utkarsh@d...> Date: Sun, 21 Jun 2020 23:23:23 +0530 Subject: [rubygems/rubygems] Use latest version of rubocop for RUBY_VERSION > 2.4 With older versions of rubocop, the dependency on `jaro_winkler` seems to be a pain. However, in the later versions of rubocop, this dependency was dropped. So we only need to use the older version for ruby2.3. Signed-off-by: Utkarsh Gupta <utkarsh@d...> https://github.com/rubygems/rubygems/commit/9cd87eaee3 diff --git a/spec/bundler/commands/newgem_spec.rb b/spec/bundler/commands/newgem_spec.rb index 4427a65..33ea617 100644 --- a/spec/bundler/commands/newgem_spec.rb +++ b/spec/bundler/commands/newgem_spec.rb @@ -177,7 +177,8 @@ RSpec.describe "bundle gem" do https://github.com/ruby/ruby/blob/trunk/spec/bundler/commands/newgem_spec.rb#L177 it "run rubocop inside the generated gem with no offenses" do prepare_gemspec(bundled_app(gem_name, "#{gem_name}.gemspec")) - gems = ["rake", "rubocop -v 0.80.1"] + rubocop_version = RUBY_VERSION > "2.4" ? "0.85.1" : "0.80.1" + gems = ["rake", "rubocop -v #{rubocop_version}"] path = Bundler.feature_flag.default_install_uses_path? ? local_gem_path(:base => bundled_app(gem_name)) : system_gem_path realworld_system_gems gems, :path => path bundle "exec rubocop --config .rubocop.yml", :dir => bundled_app(gem_name) -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/