.rubocop.yml in template_params-0.1.1 vs .rubocop.yml in template_params-0.2.0
- old
+ new
@@ -1,31 +1,50 @@
AllCops:
- TargetRubyVersion: 2.3
+ TargetRubyVersion: 2.2
-# The number of lines in a method is not a useful metric compared to `AbcSize`.
-# It's common to have very long methods (> 50 lines) which are quite simple. For
-# example, a method that returns a long string with only a few interpolations.
+Layout/AlignParameters:
+ EnforcedStyle: with_fixed_indentation
+
+# Used consistently, both leading and trailing styles are valid, but
+# Singlebrook happens to use the trailing style.
+Layout/DotPosition:
+ EnforcedStyle: trailing
+
+Layout/MultilineMethodCallBraceLayout:
+ Enabled: false
+
+Layout/MultilineMethodCallIndentation:
+ EnforcedStyle: indented
+
+Layout/MultilineOperationIndentation:
+ EnforcedStyle: indented
+
+# Not a useful metric compared to, e.g. `AbcSize`.
+Metrics/BlockLength:
+ Enabled: false
+
+# Not a useful metric compared to, e.g. `AbcSize`.
+Metrics/ClassLength:
+ Enabled: false
+
+# Not a useful metric compared to, e.g. `AbcSize`.
Metrics/MethodLength:
Enabled: false
-Style/AlignParameters:
- EnforcedStyle: with_fixed_indentation
+# Use numbers wherever you like in your variables. Who cares.
+Naming/VariableNumber:
+ Enabled: false
# Use the semantic style. If a block has side effects use `do`, and if it is
# pure use `{}`. This style is too nuanced for a linter, so the cop is
# disabled.
Style/BlockDelimiters:
Enabled: false
Style/BracesAroundHashParameters:
EnforcedStyle: context_dependent
-# Used consistently, both leading and trailing styles are valid, but
-# Singlebrook happens to use the trailing style.
-Style/DotPosition:
- EnforcedStyle: trailing
-
# Use double negation wherever it would otherwise be impractical to convert
# a value to an actual boolean.
Style/DoubleNegation:
Enabled: false
@@ -39,45 +58,10 @@
# The decision about when to use a guard clause is too nuanced for a linter.
Style/GuardClause:
Enabled: false
-# In a multiline method call, put the closing parenthesis on its own line.
-# The first argument may either be on the first line, or the second. Both of the
-# following are correct:
-#
-# ```
-# # A. correct
-# create(:user,
-# client: foo,
-# long_line: blah
-# )
-#
-# # B. also correct
-# create(
-# :user,
-# client: foo,
-# long_line: blah
-# )
-#
-# # C. not preferred
-# user = create :user,
-# client: foo,
-# long_line: blah
-# ```
-#
-# Rubocop supports B, but not A. This project allows both, so this cop is
-# disabled.
-Style/MultilineMethodCallBraceLayout:
- Enabled: false
-
-Style/MultilineMethodCallIndentation:
- EnforcedStyle: indented
-
-Style/MultilineOperationIndentation:
- EnforcedStyle: indented
-
# This is a new cop in rubocop 0.41, and I'm not sure if I want to adopt it yet.
Style/NumericLiteralPrefix:
Enabled: false
# Use `x > 0` because it is more specific than `x.positive?`.
@@ -99,9 +83,5 @@
# Predicate methods, aka. question-mark methods, such as `def x?; @x; end` are
# acceptable. See https://github.com/bbatsov/rubocop/issues/2736 for discussion.
Style/TrivialAccessors:
AllowPredicates: true
-
-# Use numbers wherever you like in your variables. Who cares.
-Style/VariableNumber:
- Enabled: false