Skip to content

Commit

Permalink
Merge pull request #2047 from koic/fix_unintended_document_changes_ca…
Browse files Browse the repository at this point in the history
…used_by_default_rake_task

[Fix #2044] Fix unintended document changes caused by default Rake task
  • Loading branch information
bquorning authored Feb 18, 2025
2 parents cd91408 + 30b09a3 commit e8ac379
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tasks/cops_documentation.rake
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ end

desc 'Generate docs of all cops departments'
task generate_cops_documentation: :yard_for_generate_documentation do
RuboCop::ConfigLoader.inject_defaults!("#{__dir__}/../config/default.yml")
loaded_plugins = RuboCop::ConfigLoader.default_configuration.loaded_plugins
if loaded_plugins.none? { |plugin| plugin.about.name == 'rubocop-rspec' }
RuboCop::ConfigLoader.inject_defaults!("#{__dir__}/../config/default.yml")
end

generator = CopsDocumentationGenerator.new(
departments: %w[RSpec]
Expand Down

0 comments on commit e8ac379

Please sign in to comment.