Skip to content

Commit

Permalink
Add rubocop-rake
Browse files Browse the repository at this point in the history
  • Loading branch information
tejasbubane committed Jun 29, 2021
1 parent 122109a commit e74ff40
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions .rubocop.yml
Expand Up @@ -5,6 +5,7 @@ require:
- rubocop/cop/internal_affairs
- rubocop-performance
- rubocop-rspec
- rubocop-rake

AllCops:
NewCops: enable
Expand Down
3 changes: 3 additions & 0 deletions .rubocop_todo.yml
Expand Up @@ -68,3 +68,6 @@ RSpec/SubjectStub:
- 'spec/rubocop/config_spec.rb'
- 'spec/rubocop/formatter/json_formatter_spec.rb'
- 'spec/rubocop/formatter/progress_formatter_spec.rb'

Rake/MethodDefinitionInTask:
Enabled: false
1 change: 1 addition & 0 deletions Gemfile
Expand Up @@ -11,6 +11,7 @@ gem 'rspec', '~> 3.7'
# RuboCop Performance upgrade to 1.11 is postponed until
# https://github.com/rubocop/rubocop/pull/9721 will be resolved.
gem 'rubocop-performance', '~> 1.10.0'
gem 'rubocop-rake', '~> 0.6.0'
gem 'rubocop-rspec', '~> 2.3.0'
# Workaround for cc-test-reporter with SimpleCov 0.18.
# Stop upgrading SimpleCov until the following issue will be resolved.
Expand Down
1 change: 1 addition & 0 deletions Rakefile
Expand Up @@ -4,6 +4,7 @@
# and started before any application code is loaded.
require 'simplecov' if ENV['COVERAGE']

desc 'Check for no pending changelog entries before release'
task release: 'changelog:check_clean' # Before task is required

require 'bundler'
Expand Down
1 change: 1 addition & 0 deletions tasks/changelog.rake
Expand Up @@ -24,6 +24,7 @@ namespace :changelog do
system cmd
end

desc 'Check for no pending changelog entries'
task :check_clean do
next unless Changelog.pending?

Expand Down
1 change: 1 addition & 0 deletions tasks/cops_documentation.rake
Expand Up @@ -9,6 +9,7 @@ YARD::Rake::YardocTask.new(:yard_for_generate_documentation) do |task|
task.options = ['--no-output']
end

desc 'Update documentation of all cops'
task update_cops_documentation: :yard_for_generate_documentation do
deps = %w[Bundler Gemspec Layout Lint Metrics Migration Naming Security Style]
CopsDocumentationGenerator.new(departments: deps).call
Expand Down
1 change: 1 addition & 0 deletions tasks/prof.rake
Expand Up @@ -10,6 +10,7 @@ namespace :prof do
system cmd
end

desc 'Run RuboCop on itself only if dump does not exist'
task :run_if_needed, [:path] do
Rake::Task[:run].run unless File.exist?(dump_path)
end
Expand Down

0 comments on commit e74ff40

Please sign in to comment.