diff --git a/Gemfile b/Gemfile index 727ee28106..f40b2674ec 100644 --- a/Gemfile +++ b/Gemfile @@ -16,7 +16,7 @@ gem "sd_notify" gem "jruby-openssl", :platform => "jruby" -gem "rubocop", "~> 0.58.0" +gem "rubocop", "~> 0.64.0" if %w(2.2.7 2.2.8 2.2.9 2.2.10 2.3.4 2.4.1).include? RUBY_VERSION gem "stopgap_13632", "~> 1.0", :platforms => ["mri", "mingw", "x64_mingw"] diff --git a/Rakefile b/Rakefile index e932b1a0c9..4ca600c444 100644 --- a/Rakefile +++ b/Rakefile @@ -11,30 +11,7 @@ gemspec = Gem::Specification.load("puma.gemspec") Gem::PackageTask.new(gemspec).define # Add rubocop task -RuboCop::RakeTask.new do - require 'rubocop' - - # Patch RuboCop::ConfigLoader.yaml_safe_load to work with Psych >= 4.0. - module RuboCop - class ConfigLoader - class << self - def yaml_safe_load(yaml_code, filename) - if Gem::Version.new(Psych::VERSION) >= Gem::Version.new('3.1.0') - YAML.safe_load( - yaml_code, - permitted_classes: [Regexp, Symbol], - permitted_symbols: [], - aliases: true, - filename: filename - ) - else - YAML.safe_load(yaml_code, [Regexp, Symbol], [], true, filename) - end - end - end - end - end -end +RuboCop::RakeTask.new # generate extension code using Ragel (C and Java) desc "Generate extension code (C and Java) using Ragel"