@@ -150,6 +150,7 @@ AllCops:
150
150
rubocop-minitest : [minitest]
151
151
rubocop-sequel : [sequel]
152
152
rubocop-rake : [rake]
153
+ rubocop-graphql : [graphql]
153
154
154
155
# ################### Bundler ###############################
155
156
@@ -258,6 +259,15 @@ Gemspec/OrderedDependencies:
258
259
Include :
259
260
- ' **/*.gemspec'
260
261
262
+ Gemspec/RequireMFA :
263
+ Description : ' Checks that the gemspec has metadata to require MFA from RubyGems.'
264
+ Enabled : pending
265
+ VersionAdded : ' 1.23'
266
+ Reference :
267
+ - https://guides.rubygems.org/mfa-requirement-opt-in/
268
+ Include :
269
+ - ' **/*.gemspec'
270
+
261
271
Gemspec/RequiredRubyVersion :
262
272
Description : ' Checks that `required_ruby_version` of gemspec is specified and equal to `TargetRubyVersion` of .rubocop.yml.'
263
273
Enabled : true
@@ -511,13 +521,13 @@ Layout/EmptyLineBetweenDefs:
511
521
StyleGuide : ' #empty-lines-between-methods'
512
522
Enabled : true
513
523
VersionAdded : ' 0.49'
514
- VersionChanged : ' 1.7 '
524
+ VersionChanged : ' 1.23 '
515
525
EmptyLineBetweenMethodDefs : true
516
526
EmptyLineBetweenClassDefs : true
517
527
EmptyLineBetweenModuleDefs : true
518
- # If `true`, this parameter means that single line method definitions don't
519
- # need an empty line between them.
520
- AllowAdjacentOneLineDefs : false
528
+ # `AllowAdjacentOneLineDefs` means that single line method definitions don't
529
+ # need an empty line between them. `true` by default.
530
+ AllowAdjacentOneLineDefs : true
521
531
# Can be array to specify minimum and maximum number of empty lines, e.g. [1, 2]
522
532
NumberOfEmptyLines : 1
523
533
@@ -2308,6 +2318,11 @@ Lint/UselessMethodDefinition:
2308
2318
Safe : false
2309
2319
AllowComments : true
2310
2320
2321
+ Lint/UselessRuby2Keywords :
2322
+ Description : ' Finds unnecessary uses of `ruby2_keywords`.'
2323
+ Enabled : pending
2324
+ VersionAdded : ' 1.23'
2325
+
2311
2326
Lint/UselessSetterCall :
2312
2327
Description : ' Checks for useless setter call to a local variable.'
2313
2328
Enabled : true
@@ -2501,6 +2516,7 @@ Naming/FileName:
2501
2516
StyleGuide : ' #snake-case-files'
2502
2517
Enabled : true
2503
2518
VersionAdded : ' 0.50'
2519
+ VersionChanged : ' 1.23'
2504
2520
# Camel case file names listed in `AllCops:Include` and all file names listed
2505
2521
# in `AllCops:Exclude` are excluded by default. Add extra excludes here.
2506
2522
Exclude : []
@@ -2513,6 +2529,13 @@ Naming/FileName:
2513
2529
# whether each source file's class or module name matches the file name --
2514
2530
# not whether the nested module hierarchy matches the subdirectory path.
2515
2531
CheckDefinitionPathHierarchy : true
2532
+ # paths that are considered root directories, for example "lib" in most ruby projects
2533
+ # or "app/models" in rails projects
2534
+ CheckDefinitionPathHierarchyRoots :
2535
+ - lib
2536
+ - spec
2537
+ - test
2538
+ - src
2516
2539
# If non-`nil`, expect all source file names to match the following regex.
2517
2540
# Only the file name itself is matched, not the entire file path.
2518
2541
# Use anchors as necessary if you want to match the entire name rather than
@@ -4216,6 +4239,16 @@ Style/OneLineConditional:
4216
4239
VersionAdded : ' 0.9'
4217
4240
VersionChanged : ' 0.90'
4218
4241
4242
+ Style/OpenStructUse :
4243
+ Description : >-
4244
+ Avoid using OpenStruct. As of Ruby 3.0, use is officially discouraged due to performance,
4245
+ version compatibility, and potential security issues.
4246
+ Reference :
4247
+ - https://docs.ruby-lang.org/en/3.0.0/OpenStruct.html#class-OpenStruct-label-Caveats
4248
+
4249
+ Enabled : pending
4250
+ VersionAdded : ' 1.23'
4251
+
4219
4252
Style/OptionHash :
4220
4253
Description : " Don't use option hashes when you can use keyword arguments."
4221
4254
Enabled : false
0 commit comments