debian-mirror-gitlab/lib/tasks/rubocop.rake

26 lines
514 B
Ruby
Raw Normal View History

2021-03-11 19:13:27 +05:30
# frozen_string_literal: true
2019-02-15 15:39:39 +05:30
unless Rails.env.production?
require 'rubocop/rake_task'
RuboCop::RakeTask.new
2021-11-11 11:23:49 +05:30
namespace :rubocop do
namespace :todo do
desc 'Generate RuboCop todos'
2021-11-18 22:05:49 +05:30
task :generate do # rubocop:disable Rails/RakeEnvironment
2021-11-11 11:23:49 +05:30
require 'rubocop'
options = %w[
--auto-gen-config
--auto-gen-only-exclude
--exclude-limit=100000
2021-11-18 22:05:49 +05:30
--no-offense-counts
2021-11-11 11:23:49 +05:30
]
RuboCop::CLI.new.run(options)
end
end
end
2019-02-15 15:39:39 +05:30
end