diff --git a/Rakefile b/Rakefile index ae526920..6c0fd53e 100644 --- a/Rakefile +++ b/Rakefile @@ -57,16 +57,10 @@ end task update: %i[update_common_tests update_meta_schemas] -require 'rubocop/rake_task' -RuboCop::RakeTask.new(:rubocop) do |task| - # These make the rubocop experience maybe slightly less terrible - task.options = ['-D', '-S', '-E'] - - # Use Rubocop's Github Actions formatter if possible - if ENV['GITHUB_ACTIONS'] == 'true' - rubocop_spec = Gem::Specification.find_by_name('rubocop') - task.formatters << 'github' if Gem::Version.new(rubocop_spec.version) >= Gem::Version.new('1.2') - end +begin + require 'voxpupuli/rubocop/rake' +rescue LoadError + # the voxpupuli-rubocop gem is optional end task default: :test