Skip to content

Commit

Permalink
Bump RuboCop to v0.84.x
Browse files Browse the repository at this point in the history
Enable new Lint/DeprecatedOpenSSLConstant cop

Additionally:
  * Enable Layout/EmptyLinesAroundAttributeAccessor cop
  * Sort configuration by cop names alphabetically
  * Add a blank line to separate various departments
  • Loading branch information
ashmaroli committed May 21, 2020
1 parent 476ec0d commit 5649cac
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 19 deletions.
44 changes: 26 additions & 18 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,13 @@ AllCops:
- script/**/*
- vendor/**/*
- tmp/**/*
Layout/EmptyLinesAroundAttributeAccessor:

Layout/EmptyComment:
Enabled: false
Layout/EmptyLinesAroundAttributeAccessor:
Enabled: true
Layout/EndAlignment:
Severity: error
Layout/HashAlignment:
EnforcedHashRocketStyle: table
Layout/IndentationWidth:
Expand All @@ -31,18 +36,25 @@ Layout/FirstArrayElementIndentation:
EnforcedStyle: consistent
Layout/FirstHashElementIndentation:
EnforcedStyle: consistent
Layout/LineLength:
Exclude:
- !ruby/regexp /features\/.*.rb/
- Rakefile
- rake/*.rake
- Gemfile
Max: 100
Severity: warning
Layout/MultilineMethodCallIndentation:
EnforcedStyle: indented
Layout/MultilineOperationIndentation:
EnforcedStyle: indented
Layout/SpaceAroundMethodCallOperator:
Enabled: true

Lint/NestedPercentLiteral:
Exclude:
- test/test_site.rb
Layout/EmptyComment:
Enabled: false
Layout/EndAlignment:
Severity: error
Layout/SpaceAroundMethodCallOperator:
Lint/DeprecatedOpenSSLConstant:
Enabled: true
Lint/RaiseException:
Enabled: true
Expand All @@ -53,6 +65,7 @@ Lint/UnreachableCode:
Lint/Void:
Exclude:
- lib/jekyll/site.rb

Metrics/AbcSize:
Max: 21
Metrics/BlockLength:
Expand All @@ -73,14 +86,6 @@ Metrics/CyclomaticComplexity:
Exclude:
- lib/jekyll/utils.rb
- lib/jekyll/commands/serve.rb
Layout/LineLength:
Exclude:
- !ruby/regexp /features\/.*.rb/
- Rakefile
- rake/*.rake
- Gemfile
Max: 100
Severity: warning
Metrics/MethodLength:
CountComments: false
Max: 20
Expand All @@ -93,6 +98,7 @@ Metrics/ParameterLists:
Max: 4
Metrics/PerceivedComplexity:
Max: 8

Naming/FileName:
Enabled: false
Naming/HeredocDelimiterNaming:
Expand All @@ -104,6 +110,7 @@ Naming/MemoizedInstanceVariableName:
- lib/jekyll/drops/site_drop.rb
- lib/jekyll/drops/unified_payload_drop.rb
- lib/jekyll/page_without_a_file.rb

Security/MarshalLoad:
Exclude:
- !ruby/regexp /test\/.*.rb$/
Expand All @@ -112,6 +119,7 @@ Security/YAMLLoad:
Exclude:
- !ruby/regexp /features\/.*.rb/
- !ruby/regexp /test\/.*.rb$/

Style/AccessModifierDeclarations:
Enabled: false
Style/Alias:
Expand All @@ -121,8 +129,6 @@ Style/AndOr:
Style/ClassAndModuleChildren:
Exclude:
- test/**/*.rb
Style/FrozenStringLiteralComment:
EnforcedStyle: always
Style/Documentation:
Enabled: false
Style/DoubleNegation:
Expand All @@ -133,6 +139,8 @@ Style/FormatStringToken:
Exclude:
- lib/jekyll/utils/ansi.rb
- lib/jekyll/liquid_renderer/table.rb
Style/FrozenStringLiteralComment:
EnforcedStyle: always
Style/GuardClause:
Enabled: false
Style/HashEachMethods:
Expand Down Expand Up @@ -167,10 +175,10 @@ Style/RescueModifier:
Style/SafeNavigation:
Exclude:
- lib/jekyll/document.rb
Style/SlicingWithRange:
Enabled: false
Style/SignalException:
EnforcedStyle: only_raise
Style/SlicingWithRange:
Enabled: false
Style/StringLiterals:
EnforcedStyle: double_quotes
Style/StringLiteralsInInterpolation:
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ group :test do
gem "nokogiri", "~> 1.7"
gem "rspec"
gem "rspec-mocks"
gem "rubocop", "~> 0.83.0"
gem "rubocop", "~> 0.84.0"
gem "rubocop-performance"
gem "test-dependency-theme", :path => File.expand_path("test/fixtures/test-dependency-theme", __dir__)
gem "test-theme", :path => File.expand_path("test/fixtures/test-theme", __dir__)
Expand Down

0 comments on commit 5649cac

Please sign in to comment.