Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to RuboCop 0.87.1 #92

Merged
merged 1 commit into from
Jul 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions config/disable_all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -421,6 +421,8 @@ Naming/VariableNumber:
Enabled: false
Style/AccessModifierDeclarations:
Enabled: false
Style/AccessorGrouping:
Enabled: false
Style/Alias:
Enabled: false
Style/AndOr:
Expand All @@ -437,6 +439,8 @@ Style/BarePercentLiterals:
Enabled: false
Style/BeginBlock:
Enabled: false
Style/BisectedAttrAccessor:
Enabled: false
Style/BlockComments:
Enabled: false
Style/BlockDelimiters:
Expand Down Expand Up @@ -567,6 +571,8 @@ Style/MethodCallWithoutArgsParentheses:
Enabled: false
Style/MethodCallWithArgsParentheses:
Enabled: false
Style/RedundantAssignment:
Enabled: false
Style/RedundantFetchBlock:
Enabled: false
Style/MethodCalledOnDoEndBlock:
Expand Down
50 changes: 46 additions & 4 deletions config/upstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,9 @@ Bundler/OrderedGems:
VersionAdded: '0.46'
VersionChanged: '0.47'
TreatCommentsAsGroupSeparators: true
# By default, "-" and "_" are ignored for order purposes.
# This can be overridden by setting this parameter to true.
ConsiderPunctuation: false
Include:
- '**/*.gemfile'
- '**/Gemfile'
Expand All @@ -200,6 +203,9 @@ Gemspec/OrderedDependencies:
Enabled: true
VersionAdded: '0.51'
TreatCommentsAsGroupSeparators: true
# By default, "-" and "_" are ignored for order purposes.
# This can be overridden by setting this parameter to true.
ConsiderPunctuation: false
Include:
- '**/*.gemspec'

Expand Down Expand Up @@ -1508,7 +1514,9 @@ Lint/InheritException:
Lint/InterpolationCheck:
Description: 'Raise warning for interpolation in single q strs.'
Enabled: true
SafeAutoCorrect: false
VersionAdded: '0.50'
VersionChanged: '0.87'

Lint/LiteralAsCondition:
Description: 'Checks of literals used in conditions.'
Expand Down Expand Up @@ -1736,6 +1744,7 @@ Lint/SafeNavigationWithEmpty:
Description: 'Avoid `foo&.empty?` in conditionals.'
Enabled: true
VersionAdded: '0.62'
VersionChanged: '0.87'

Lint/ScriptPermission:
Description: 'Grant script file execute permission.'
Expand Down Expand Up @@ -1902,9 +1911,10 @@ Metrics/BlockLength:
Description: 'Avoid long blocks with many lines.'
Enabled: true
VersionAdded: '0.44'
VersionChanged: '0.66'
VersionChanged: '0.87'
CountComments: false # count full line comments?
Max: 25
CountAsOne: []
ExcludedMethods:
# By default, exclude the `#refine` method, as it tends to have larger
# associated blocks.
Expand All @@ -1925,8 +1935,10 @@ Metrics/ClassLength:
Description: 'Avoid classes longer than 100 lines of code.'
Enabled: true
VersionAdded: '0.25'
VersionChanged: '0.87'
CountComments: false # count full line comments?
Max: 100
CountAsOne: []

# Avoid complex methods.
Metrics/CyclomaticComplexity:
Expand All @@ -1944,17 +1956,20 @@ Metrics/MethodLength:
StyleGuide: '#short-methods'
Enabled: true
VersionAdded: '0.25'
VersionChanged: '0.59.2'
VersionChanged: '0.87'
CountComments: false # count full line comments?
Max: 10
CountAsOne: []
ExcludedMethods: []

Metrics/ModuleLength:
Description: 'Avoid modules longer than 100 lines of code.'
Enabled: true
VersionAdded: '0.31'
VersionChanged: '0.87'
CountComments: false # count full line comments?
Max: 100
CountAsOne: []

Metrics/ParameterLists:
Description: 'Avoid parameter lists longer than three or four parameters.'
Expand Down Expand Up @@ -1992,10 +2007,12 @@ Naming/AccessorMethodName:
VersionAdded: '0.50'

Naming/AsciiIdentifiers:
Description: 'Use only ascii symbols in identifiers.'
Description: 'Use only ascii symbols in identifiers and constants.'
StyleGuide: '#english-identifiers'
Enabled: true
VersionAdded: '0.50'
VersionChanged: '0.87'
AsciiConstants: true

Naming/BinaryOperatorParameterName:
Description: 'When defining binary operators, name the argument other.'
Expand Down Expand Up @@ -2288,6 +2305,17 @@ Style/AccessModifierDeclarations:
- group
AllowModifiersOnSymbols: true

Style/AccessorGrouping:
Description: 'Checks for grouping of accessors in `class` and `module` bodies.'
Enabled: 'pending'
VersionAdded: '0.87'
EnforcedStyle: grouped
SupportedStyles:
# separated: each accessor goes in a separate statement.
# grouped: accessors are grouped into a single statement.
- separated
- grouped

Style/Alias:
Description: 'Use alias instead of alias_method.'
StyleGuide: '#alias-method-lexically'
Expand Down Expand Up @@ -2355,6 +2383,13 @@ Style/BeginBlock:
Enabled: true
VersionAdded: '0.9'

Style/BisectedAttrAccessor:
Description: >-
Checks for places where `attr_reader` and `attr_writer`
for the same method can be combined into single `attr_accessor`.
Enabled: 'pending'
VersionAdded: '0.87'

Style/BlockComments:
Description: 'Do not use block comments.'
StyleGuide: '#no-block-comments'
Expand Down Expand Up @@ -2729,6 +2764,7 @@ Style/DoubleNegation:
VersionAdded: '0.19'
VersionChanged: '0.84'
EnforcedStyle: allowed_in_returns
SafeAutoCorrect: false
SupportedStyles:
- allowed_in_returns
- forbidden
Expand Down Expand Up @@ -2995,6 +3031,7 @@ Style/IfUnlessModifierOfIfUnless:
Avoid modifier if/unless usage on conditionals.
Enabled: true
VersionAdded: '0.39'
VersionChanged: '0.87'

Style/IfWithSemicolon:
Description: 'Do not use if x; .... Use the ternary operator instead.'
Expand Down Expand Up @@ -3581,6 +3618,11 @@ Style/RandomWithOffset:
Enabled: true
VersionAdded: '0.52'

Style/RedundantAssignment:
Description: 'Checks for redundant assignment before returning.'
Enabled: 'pending'
VersionAdded: '0.87'

Style/RedundantBegin:
Description: "Don't use begin blocks when they are not needed."
StyleGuide: '#begin-implicit'
Expand Down Expand Up @@ -3924,7 +3966,7 @@ Style/SymbolLiteral:
Style/SymbolProc:
Description: 'Use symbols as procs instead of blocks when possible.'
Enabled: true
SafeAutoCorrect: false
Safe: false
VersionAdded: '0.26'
VersionChanged: '0.64'
# A list of method names to be ignored by the check.
Expand Down
2 changes: 1 addition & 1 deletion lib/chefstyle/version.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module Chefstyle
VERSION = "1.1.2".freeze
RUBOCOP_VERSION = "0.86.0".freeze
RUBOCOP_VERSION = "0.87.1".freeze
end