Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Add rubocop-performance

Klaus Zanders7a3c3bbc2d42
diff --git a/.rubocop.yml b/.rubocop.yml
index be7279bbbdc..1800b351ff3 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -5,6 +5,7 @@ require:
- ./lib_static/rubocop/cop/open_project/use_service_result_factory_methods.rb
- rubocop-capybara
- rubocop-factory_bot
+ - rubocop-performance
<% if File.exist?('.rubocop-local.yml') %>
inherit_from:
diff --git a/Gemfile b/Gemfile
index 35a4543de49..c8b7cee1c8b 100644
--- a/Gemfile
+++ b/Gemfile
@@ -308,6 +308,7 @@ group :development, :test do
gem 'rubocop', require: false
gem 'rubocop-rails', require: false
gem 'rubocop-rspec', require: false
+ gem 'rubocop-performance', require: false
# Brakeman scanner
gem 'brakeman', '~> 6.0.0'
diff --git a/Gemfile.lock b/Gemfile.lock
index 1eb1ac2697d..e894165f698 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -858,6 +858,9 @@ GEM
rubocop (~> 1.41)
rubocop-factory_bot (2.23.1)
rubocop (~> 1.33)
+ rubocop-performance (1.19.0)
+ rubocop (>= 1.7.0, < 2.0)
+ rubocop-ast (>= 0.4.0)
rubocop-rails (2.20.2)
activesupport (>= 4.2.0)
rack (>= 1.1)
@@ -1135,6 +1138,7 @@ DEPENDENCIES
rspec-rails (~> 6.0.0)
rspec-retry (~> 0.6.1)
rubocop
+ rubocop-performance
rubocop-rails
rubocop-rspec
ruby-duration (~> 3.2.0)