Skip to content

Commit

Permalink
Allow a recent version of Rubocop
Browse files Browse the repository at this point in the history
Than old version of Rubocop only work with an outdated version of Ruby.
With modern Ruby, we need a more recent version of Rubocop.  Adjust the
configuration accordingly and ignore the new borring offenses.
  • Loading branch information
smortex committed Aug 25, 2024
1 parent e2f3579 commit c8979b3
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 19 deletions.
37 changes: 20 additions & 17 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,6 @@ Style/TrailingUnderscoreVariable:
Lint/NonLocalExitFromIterator:
Enabled: false

Style/TrailingUnderscoreVariable:
Enabled: false

Naming/ClassAndModuleCamelCase:
Enabled: false

Expand Down Expand Up @@ -68,9 +65,6 @@ Layout/SpaceInsideBlockBraces:
Layout/SpaceInsideHashLiteralBraces:
EnforcedStyle: no_space

Style/Documentation:
Severity: warning

Style/EachWithObject:
Enabled: false

Expand Down Expand Up @@ -104,7 +98,7 @@ Lint/UnusedMethodArgument:
Lint/AssignmentInCondition:
Enabled: false

Metrics/LineLength:
Layout/LineLength:
Max: 180

Metrics/PerceivedComplexity:
Expand All @@ -131,9 +125,6 @@ Metrics/ModuleLength:
Metrics/BlockLength:
Enabled: false

Performance/Casecmp:
Enabled: false

Style/FrozenStringLiteralComment:
Enabled: false

Expand All @@ -143,21 +134,33 @@ Style/SymbolArray:
Security/MarshalLoad:
Enabled: false

Layout/IndentHeredoc:
Layout/HeredocIndentation:
Enabled: false

# @todo use safe_load but its a big change
Security/YAMLLoad:
Layout/HashAlignment:
Enabled: false

Performance/RegexpMatch:
Style/FormatStringToken:
Enabled: false

Style/SafeNavigation:
Style/RedundantBegin:
Enabled: false

Lint/RescueWithoutErrorClass:
Style/IfUnlessModifier:
Enabled: false

Naming/MethodParameterName:
Enabled: false

Lint/ConstantDefinitionInBlock:
Enabled: false

# @todo use safe_load but its a big change
Security/YAMLLoad:
Enabled: false

Style/SafeNavigation:
Enabled: false

Performance/StringReplacement:
Style/RescueStandardError:
Enabled: false
4 changes: 2 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ group :test do
gem "mocha"
gem "rake"
gem "rspec"
gem "rubocop", "0.51.0"
gem "rubocop"
gem "sys-proctable"
end

Expand All @@ -16,5 +16,5 @@ mcollective_version = ENV["MCOLLECTIVE_GEM_VERSION"]
if mcollective_version
gem "mcollective-client", mcollective_version, :require => false
else
gem "mcollective-client", :require => false # rubocop:disable Bundler/DuplicatedGem
gem "mcollective-client", :require => false
end

0 comments on commit c8979b3

Please sign in to comment.