.rubocop.yml in webpacker-pnpm-1.2.0 vs .rubocop.yml in webpacker-pnpm-1.2.1
- old
+ new
@@ -1,91 +1,25 @@
-require: rubocop-rails
-AllCops:
- Exclude:
- - "node_modules/**/*"
-
-# disable length length checking, as it tends to make things worse in the majority
-# of cases. however, it is good practice keep lines <= 85 columns so they remain
-# readable.
-Layout/LineLength:
- Enabled: false
-
-# disable documentation checking. many classes do not require top-level comments,
-# and their inclusion can actually obscure their function.
-Style/Documentation:
- Enabled: false
-
-# functionalization is important, but the Rails' idiom for returning key-value
-# maps can raise a false alarm with the max line number (10). increase the value
-# to something more reasonable given the circumstances.
-Metrics/MethodLength:
- Max: 20
- ExcludedMethods:
- - test_rake_tasks
-
-# if you're specifying access modifiers, it is likely intentional. force RuboCop
-# to trust your decision making.
-Lint/UselessAccessModifier:
- Enabled: false
-
-# flag potential memory leaks, like when opening a file.
-Style/AutoResourceCleanup:
- Enabled: true
-
-# single quotes are meant for single characters. double quotes are meant for
-# strings, which are arrays of multiple characters. there are a whole host of
-# other differences and functions; if you're creating a string, you nearly always
-# should use double quotes.
-#
-# https://en.wikipedia.org/wiki/Delimiter#Bracket_delimiters
-# Schwartz, Randal (2005). Learning Perl. ISBN 978-0-596-10105-3.
-Style/StringLiterals:
- Enabled: true
- EnforcedStyle: double_quotes
-
-# flags methods that violate the default ABC magnitude (15). The ABC metric
-# quantizes the size of a method, and is calculated based on the number of
-# assignment operations, possible execution branches, and number of conditionals.
-#
-# https://en.wikipedia.org/wiki/ABC_Software_Metric
-Metrics/AbcSize:
- Enabled: true
- IgnoredMethods:
- - test_rake_tasks
- - chdir_concurrent
-
-# this simply doesn't work in a cross-platform development environment. Bit
-# flags across UNIX and Windows platforms are volatile, and thus there is no
-# way to ensure this passes besides explicitly granting execute permissions
-# in CI config (which would defeat the purpose).
-Lint/ScriptPermission:
- Enabled: false
-
-Layout/SpaceAroundMethodCallOperator:
- Enabled: true
-
-Lint/RaiseException:
- Enabled: true
-
-Lint/StructNewOverride:
- Enabled: true
-
-Style/ExponentialNotation:
- Enabled: true
-
-Style/HashEachMethods:
- Enabled: true
-
-Style/HashTransformKeys:
- Enabled: true
-
-Style/HashTransformValues:
- Enabled: true
-
-Layout/EmptyLinesAroundAttributeAccessor:
- Enabled: true
-
-Style/SlicingWithRange:
- Enabled: true
-
-Style/RescueModifier:
- Enabled: false
\ No newline at end of file
+#
+# RuboCop is a Ruby static code analyzer and code formatter that tries to enforce many of
+# the guidelines outlined in the community Ruby and Rails
+# style guides.
+#
+# https://docs.rubocop.org/en/latest/
+# https://rubystyle.guide/
+# https://rails.rubystyle.guide/
+inherit_gem:
+ practical-pig: rubocop-base.yaml
+inherit_mode:
+ merge:
+ - Include
+ - Exclude
+ - IgnoredMethods
+ - AllowedMethods
+
+# cop-specific excludes are not inherited for some reason (likely a bug in RuboCop) so we
+# need to manually re-omit the intended files and directories.
+Layout/LineLength:
+ Exclude:
+ - "**/config/initializers/**/*"
+Style/MethodCallWithArgsParentheses:
+ Exclude:
+ - "**/Gemfile"