Skip to content

Commit

Permalink
Update the Rubocop config
Browse files Browse the repository at this point in the history
to make it work with Rubocop 0.40.0
  • Loading branch information
lslezak committed Jun 9, 2016
1 parent d5beade commit f853098
Showing 1 changed file with 43 additions and 1 deletion.
44 changes: 43 additions & 1 deletion ytools/y2tool/rubocop_yast_style.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@

# Disabled, would require too many changes in the current code
#Lint/EndAlignment:
# StyleGuide: https://github.com/SUSE/style-guides/blob/master/Ruby.md#lintendalignment
# StyleGuide: https://github.com/SUSE/style-guides/blob/master/Ruby.md#lintendalignment
# AlignWith: variable

AllCops:
TargetRubyVersion: 2.1

Metrics/AbcSize:
StyleGuide: https://github.com/SUSE/style-guides/blob/master/Ruby.md#metricsabcsize
Max: 30
Expand Down Expand Up @@ -199,3 +202,42 @@ Style/AsciiComments:
#
Style/DoubleNegation:
Enabled: false

# New Rubocop uses a different default ("special_inside_parentheses")
# which adds too much indentation in some cases. Use the backward compatible value.
Style/IndentArray:
EnforcedStyle: consistent

# Use the backward compatible default
Lint/EndAlignment:
AlignWith: start_of_line

# Allow block.call:
#
# def foo(&block)
# var = block,call
# ...
#
# is better readable than
#
# def foo
# var = yield
# ...
#
# athough it is a bit slower
Performance/RedundantBlockCall:
Enabled: false

# Use the backward compatible default
Style/MultilineMethodCallIndentation:
EnforcedStyle: indented

# Do not check the module length, the YCP converted includes
# are usually too long.
Metrics/ModuleLength:
Enabled: false

# Disable the "foo.size == 0" check, Yast::Term does not provide #empty?
Style/ZeroLengthPredicate:
Enabled: false

0 comments on commit f853098

Please sign in to comment.