codeowner_validator 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. checksums.yaml +7 -0
  2. data/.github/ISSUE_TEMPLATE/bug_report.md +32 -0
  3. data/.github/ISSUE_TEMPLATE/config.yml +6 -0
  4. data/.github/ISSUE_TEMPLATE/feature_request.md +30 -0
  5. data/.github/pull_request_template.md +32 -0
  6. data/.github/workflows/cd.yml +53 -0
  7. data/.github/workflows/ci.yml +39 -0
  8. data/.gitignore +23 -0
  9. data/.rspec +4 -0
  10. data/.rubocop.yml +926 -0
  11. data/.ruby-gemset +1 -0
  12. data/.ruby-version +1 -0
  13. data/.vscode/launch.json +53 -0
  14. data/CHANGELOG.md +5 -0
  15. data/CODE_OF_CONDUCT.md +74 -0
  16. data/CONTRIBUTING.md +40 -0
  17. data/CONTRIBUTORS.md +3 -0
  18. data/Gemfile +20 -0
  19. data/LICENSE +205 -0
  20. data/NOTICE +13 -0
  21. data/README.md +160 -0
  22. data/Rakefile +8 -0
  23. data/bin/bundle-audit +29 -0
  24. data/bin/bundler-audit +29 -0
  25. data/bin/codeowner_validator +8 -0
  26. data/bin/rake +29 -0
  27. data/bin/rspec +29 -0
  28. data/bin/rubocop +29 -0
  29. data/codeowner_validator.gemspec +41 -0
  30. data/lib/codeowner_validator/cli/validator_cli.rb +64 -0
  31. data/lib/codeowner_validator/code_owners.rb +308 -0
  32. data/lib/codeowner_validator/common/command.rb +40 -0
  33. data/lib/codeowner_validator/common/logging.rb +86 -0
  34. data/lib/codeowner_validator/common/tasks/base.rb +62 -0
  35. data/lib/codeowner_validator/group/comment/error.rb +21 -0
  36. data/lib/codeowner_validator/group/comment/info.rb +21 -0
  37. data/lib/codeowner_validator/group/comment/verbose.rb +21 -0
  38. data/lib/codeowner_validator/group/comment/warn.rb +21 -0
  39. data/lib/codeowner_validator/group/comment.rb +55 -0
  40. data/lib/codeowner_validator/helpers/config_helper.rb +73 -0
  41. data/lib/codeowner_validator/helpers/utility_helper.rb +30 -0
  42. data/lib/codeowner_validator/lists/whitelist.rb +145 -0
  43. data/lib/codeowner_validator/tasks/duplicate_checker.rb +32 -0
  44. data/lib/codeowner_validator/tasks/file_exists_checker.rb +35 -0
  45. data/lib/codeowner_validator/tasks/missing_assignment_checker.rb +32 -0
  46. data/lib/codeowner_validator/tasks/syntax_checker.rb +32 -0
  47. data/lib/codeowner_validator/validator.rb +76 -0
  48. data/lib/codeowner_validator/version.rb +11 -0
  49. data/lib/codeowner_validator.rb +32 -0
  50. data/lib/codeowners/checker/group/line.rb +12 -0
  51. metadata +204 -0
data/.rubocop.yml ADDED
@@ -0,0 +1,926 @@
1
+ require:
2
+ - rubocop-performance
3
+ - rubocop-rspec
4
+ - rubocop-rake
5
+
6
+ AllCops:
7
+ TargetRubyVersion: 2.6
8
+ DisabledByDefault: true
9
+ Exclude:
10
+ - 'bin/{bundle,bundle-audit,bundler-audit,rake,rspec,rubocop}'
11
+ - 'target/**/*'
12
+ - 'vendor/**/*'
13
+ - 'build/**/*'
14
+ - 'pkg/**/*'
15
+ - 'tmp/**/*'
16
+
17
+ # Bundler Cop Configuration
18
+ # https://docs.rubocop.org/en/stable/cops_bundler/
19
+
20
+ Bundler/DuplicatedGem:
21
+ Enabled: true
22
+ Bundler/GemComment:
23
+ # Disabled. Comments for each gem declaration are not required.
24
+ Enabled: false
25
+ Bundler/InsecureProtocolSource:
26
+ Enabled: true
27
+ Bundler/OrderedGems:
28
+ Enabled: true
29
+
30
+ # Gemspec Cop Configuration
31
+ # https://docs.rubocop.org/en/stable/cops_gemspec/
32
+
33
+ Gemspec/DuplicatedAssignment:
34
+ Enabled: true
35
+ Gemspec/OrderedDependencies:
36
+ Enabled: true
37
+ Gemspec/RequiredRubyVersion:
38
+ Enabled: true
39
+ Gemspec/RubyVersionGlobalsUsage:
40
+ Enabled: true
41
+
42
+ # Layout Cop Configuration
43
+ # https://docs.rubocop.org/en/stable/cops_layout/
44
+
45
+ Layout/AccessModifierIndentation:
46
+ Enabled: true
47
+ Layout/ArgumentAlignment:
48
+ Enabled: true
49
+ Layout/ArrayAlignment:
50
+ Enabled: true
51
+ Layout/AssignmentIndentation:
52
+ Enabled: true
53
+ Layout/BlockAlignment:
54
+ Enabled: true
55
+ Layout/BlockEndNewline:
56
+ Enabled: true
57
+ Layout/CaseIndentation:
58
+ Enabled: true
59
+ Layout/ClassStructure:
60
+ Enabled: true
61
+ Layout/ClosingHeredocIndentation:
62
+ Enabled: true
63
+ Layout/ClosingParenthesisIndentation:
64
+ Enabled: true
65
+ Layout/CommentIndentation:
66
+ Enabled: true
67
+ Layout/ConditionPosition:
68
+ Enabled: true
69
+ Layout/DefEndAlignment:
70
+ Enabled: true
71
+ Layout/DotPosition:
72
+ Enabled: true
73
+ Layout/ElseAlignment:
74
+ Enabled: true
75
+ Layout/EmptyComment:
76
+ Enabled: true
77
+ Layout/EmptyLineAfterGuardClause:
78
+ Enabled: true
79
+ Layout/EmptyLineAfterMagicComment:
80
+ Enabled: true
81
+ Layout/EmptyLineBetweenDefs:
82
+ Enabled: true
83
+ Layout/EmptyLines:
84
+ Enabled: true
85
+ Layout/EmptyLinesAroundAccessModifier:
86
+ Enabled: true
87
+ Layout/EmptyLinesAroundArguments:
88
+ Enabled: true
89
+ Layout/EmptyLinesAroundBeginBody:
90
+ Enabled: true
91
+ Layout/EmptyLinesAroundBlockBody:
92
+ Enabled: true
93
+ Layout/EmptyLinesAroundClassBody:
94
+ Enabled: true
95
+ Layout/EmptyLinesAroundExceptionHandlingKeywords:
96
+ Enabled: true
97
+ Layout/EmptyLinesAroundMethodBody:
98
+ Enabled: true
99
+ Layout/EmptyLinesAroundModuleBody:
100
+ Enabled: true
101
+ Layout/EndAlignment:
102
+ Enabled: true
103
+ Layout/EndOfLine:
104
+ Enabled: true
105
+ Layout/ExtraSpacing:
106
+ Enabled: true
107
+ Layout/FirstArgumentIndentation:
108
+ Enabled: true
109
+ Layout/FirstArrayElementIndentation:
110
+ Enabled: true
111
+ Layout/FirstArrayElementLineBreak:
112
+ Enabled: true
113
+ Layout/FirstHashElementLineBreak:
114
+ Enabled: true
115
+ Layout/FirstHashElementIndentation:
116
+ Enabled: true
117
+ Layout/FirstMethodArgumentLineBreak:
118
+ Enabled: true
119
+ Layout/FirstMethodParameterLineBreak:
120
+ Enabled: true
121
+ Layout/FirstParameterIndentation:
122
+ Enabled: true
123
+ Layout/HashAlignment:
124
+ Enabled: true
125
+ Layout/HeredocArgumentClosingParenthesis:
126
+ Enabled: true
127
+ Layout/HeredocIndentation:
128
+ Enabled: true
129
+ Layout/IndentationConsistency:
130
+ Enabled: true
131
+ Layout/IndentationStyle:
132
+ Enabled: true
133
+ EnforcedStyle: spaces
134
+ IndentationWidth: 2
135
+ Layout/IndentationWidth:
136
+ Enabled: true
137
+ Layout/InitialIndentation:
138
+ Enabled: true
139
+ Layout/LeadingEmptyLines:
140
+ Enabled: true
141
+ Layout/LeadingCommentSpace:
142
+ Enabled: true
143
+ Layout/LineLength:
144
+ # Lines are allowed to be a maximum of 120 characters. However, it is suggested that, in practice,
145
+ # line should be kept to a maximum of 100 for readability, especially within comments.
146
+ Enabled: true
147
+ AutoCorrect: true
148
+ Max: 120
149
+ Layout/MultilineArrayBraceLayout:
150
+ Enabled: true
151
+ Layout/MultilineArrayLineBreaks:
152
+ Enabled: true
153
+ Layout/MultilineAssignmentLayout:
154
+ Enabled: true
155
+ Layout/MultilineBlockLayout:
156
+ Enabled: true
157
+ Layout/MultilineHashBraceLayout:
158
+ Enabled: true
159
+ Layout/MultilineHashKeyLineBreaks:
160
+ Enabled: true
161
+ Layout/MultilineMethodArgumentLineBreaks:
162
+ Enabled: true
163
+ Layout/MultilineMethodCallBraceLayout:
164
+ Enabled: true
165
+ Layout/MultilineMethodCallIndentation:
166
+ Enabled: true
167
+ Layout/MultilineMethodDefinitionBraceLayout:
168
+ Enabled: true
169
+ Layout/MultilineOperationIndentation:
170
+ Enabled: true
171
+ Layout/ParameterAlignment:
172
+ Enabled: true
173
+ Layout/RescueEnsureAlignment:
174
+ Enabled: true
175
+ Layout/SpaceAfterColon:
176
+ Enabled: true
177
+ Layout/SpaceAfterComma:
178
+ Enabled: true
179
+ Layout/SpaceAfterMethodName:
180
+ Enabled: true
181
+ Layout/SpaceAfterNot:
182
+ Enabled: true
183
+ Layout/SpaceAfterSemicolon:
184
+ Enabled: true
185
+ Layout/SpaceAroundBlockParameters:
186
+ Enabled: true
187
+ Layout/SpaceAroundEqualsInParameterDefault:
188
+ Enabled: true
189
+ Layout/SpaceAroundKeyword:
190
+ Enabled: true
191
+ Layout/SpaceAroundMethodCallOperator:
192
+ Enabled: true
193
+ Layout/SpaceAroundOperators:
194
+ Enabled: true
195
+ Layout/SpaceBeforeBlockBraces:
196
+ Enabled: true
197
+ Layout/SpaceBeforeComma:
198
+ Enabled: true
199
+ Layout/SpaceBeforeComment:
200
+ Enabled: true
201
+ Layout/SpaceBeforeFirstArg:
202
+ Enabled: true
203
+ Layout/SpaceBeforeSemicolon:
204
+ Enabled: true
205
+ Layout/SpaceInLambdaLiteral:
206
+ Enabled: true
207
+ Layout/SpaceInsideArrayLiteralBrackets:
208
+ Enabled: true
209
+ Layout/SpaceInsideArrayPercentLiteral:
210
+ Enabled: true
211
+ Layout/SpaceInsideBlockBraces:
212
+ Enabled: true
213
+ Layout/SpaceInsideHashLiteralBraces:
214
+ Enabled: true
215
+ Layout/SpaceInsideParens:
216
+ Enabled: true
217
+ Layout/SpaceInsidePercentLiteralDelimiters:
218
+ Enabled: true
219
+ Layout/SpaceInsideRangeLiteral:
220
+ Enabled: true
221
+ Layout/SpaceInsideReferenceBrackets:
222
+ Enabled: true
223
+ Layout/SpaceInsideStringInterpolation:
224
+ Enabled: true
225
+ Layout/TrailingEmptyLines:
226
+ Enabled: true
227
+ Layout/TrailingWhitespace:
228
+ Enabled: true
229
+
230
+ # Lint Cop Configuration
231
+ # https://docs.rubocop.org/en/stable/cops_lint/
232
+
233
+ Lint/AmbiguousBlockAssociation:
234
+ Enabled: true
235
+ Lint/AmbiguousOperator:
236
+ Enabled: true
237
+ Lint/AmbiguousRegexpLiteral:
238
+ Enabled: true
239
+ Lint/AssignmentInCondition:
240
+ Enabled: true
241
+ Lint/BigDecimalNew:
242
+ Enabled: true
243
+ # Supercedes Lint/UselessComparison in rubocop 0.89.
244
+ Lint/BinaryOperatorWithIdenticalOperands:
245
+ Enabled: true
246
+ Lint/BooleanSymbol:
247
+ Enabled: true
248
+ Lint/CircularArgumentReference:
249
+ Enabled: true
250
+ Lint/Debugger:
251
+ Enabled: true
252
+ Lint/DeprecatedClassMethods:
253
+ Enabled: true
254
+ Lint/DisjunctiveAssignmentInConstructor:
255
+ Enabled: true
256
+ Lint/DuplicateCaseCondition:
257
+ Enabled: true
258
+ Lint/DuplicateMethods:
259
+ Enabled: true
260
+ Lint/DuplicateHashKey:
261
+ Enabled: true
262
+ Lint/EachWithObjectArgument:
263
+ Enabled: true
264
+ Lint/ElseLayout:
265
+ Enabled: true
266
+ Lint/EmptyEnsure:
267
+ Enabled: true
268
+ Lint/EmptyExpression:
269
+ Enabled: true
270
+ Lint/EmptyInterpolation:
271
+ Enabled: true
272
+ Lint/EmptyWhen:
273
+ Enabled: true
274
+ Lint/EnsureReturn:
275
+ Enabled: true
276
+ Lint/ErbNewArguments:
277
+ Enabled: true
278
+ Lint/FlipFlop:
279
+ Enabled: true
280
+ Lint/FloatOutOfRange:
281
+ Enabled: true
282
+ Lint/FormatParameterMismatch:
283
+ Enabled: true
284
+ Lint/HeredocMethodCallPosition:
285
+ Enabled: true
286
+ Lint/ImplicitStringConcatenation:
287
+ Enabled: true
288
+ Lint/IneffectiveAccessModifier:
289
+ Enabled: true
290
+ Lint/InheritException:
291
+ Enabled: true
292
+ Lint/InterpolationCheck:
293
+ Enabled: true
294
+ Lint/LiteralAsCondition:
295
+ Enabled: true
296
+ Lint/LiteralInInterpolation:
297
+ Enabled: true
298
+ Lint/Loop:
299
+ Enabled: true
300
+ Lint/MissingCopEnableDirective:
301
+ Enabled: true
302
+ Lint/MissingSuper:
303
+ # Disabled. This cop is well-meaning, but doesn't provide exemption of cases where invocation of
304
+ # super is not possible. Supercedes Style/MethodMissingSuper in rubocop 0.89.
305
+ Enabled: false
306
+ Lint/MultipleComparison:
307
+ Enabled: true
308
+ Lint/NestedMethodDefinition:
309
+ Enabled: true
310
+ Lint/NestedPercentLiteral:
311
+ Enabled: true
312
+ Lint/NextWithoutAccumulator:
313
+ Enabled: true
314
+ Lint/NonLocalExitFromIterator:
315
+ Enabled: true
316
+ Lint/NumberConversion:
317
+ Enabled: false
318
+ Lint/OrderedMagicComments:
319
+ Enabled: true
320
+ Lint/ParenthesesAsGroupedExpression:
321
+ Enabled: true
322
+ Lint/PercentStringArray:
323
+ Enabled: true
324
+ Lint/PercentSymbolArray:
325
+ Enabled: true
326
+ Lint/RandOne:
327
+ Enabled: true
328
+ Lint/RedundantCopDisableDirective:
329
+ Enabled: true
330
+ Lint/RedundantCopEnableDirective:
331
+ Enabled: true
332
+ Lint/RedundantRequireStatement:
333
+ Enabled: true
334
+ Lint/RedundantSplatExpansion:
335
+ Enabled: true
336
+ Lint/RedundantStringCoercion:
337
+ Enabled: true
338
+ Lint/RedundantWithIndex:
339
+ Enabled: true
340
+ Lint/RedundantWithObject:
341
+ Enabled: true
342
+ Lint/RegexpAsCondition:
343
+ Enabled: true
344
+ Lint/RequireParentheses:
345
+ Enabled: true
346
+ Lint/RescueException:
347
+ Enabled: true
348
+ Lint/RescueType:
349
+ Enabled: true
350
+ Lint/ReturnInVoidContext:
351
+ Enabled: true
352
+ Lint/SafeNavigationChain:
353
+ Enabled: true
354
+ Lint/SafeNavigationConsistency:
355
+ Enabled: true
356
+ Lint/SafeNavigationWithEmpty:
357
+ Enabled: true
358
+ Lint/ScriptPermission:
359
+ Enabled: true
360
+ Lint/ShadowedArgument:
361
+ Enabled: true
362
+ Lint/ShadowedException:
363
+ Enabled: true
364
+ Lint/ShadowingOuterLocalVariable:
365
+ Enabled: true
366
+ Lint/SuppressedException:
367
+ Enabled: true
368
+ Lint/Syntax:
369
+ Enabled: true
370
+ Lint/ToJSON:
371
+ Enabled: true
372
+ Lint/UnderscorePrefixedVariableName:
373
+ Enabled: true
374
+ Lint/UnifiedInteger:
375
+ Enabled: true
376
+ Lint/UnreachableCode:
377
+ Enabled: true
378
+ Lint/UnusedBlockArgument:
379
+ Enabled: true
380
+ Lint/UnusedMethodArgument:
381
+ Enabled: true
382
+ Lint/UriEscapeUnescape:
383
+ Enabled: true
384
+ Lint/UriRegexp:
385
+ Enabled: true
386
+ Lint/UselessAccessModifier:
387
+ Enabled: true
388
+ Lint/UselessAssignment:
389
+ Enabled: true
390
+ Lint/UselessElseWithoutRescue:
391
+ Enabled: true
392
+ Lint/UselessSetterCall:
393
+ Enabled: true
394
+ Lint/Void:
395
+ Enabled: true
396
+
397
+ # Metrics Cop Configuration
398
+ # https://docs.rubocop.org/en/stable/cops_metrics/
399
+
400
+ Metrics/AbcSize:
401
+ # Disabled along with all length metric constraints are considered arbitrary and arguably
402
+ # don't provide enough value for their use.
403
+ Enabled: false
404
+ Metrics/BlockLength:
405
+ # Disabled, see Metrics/AbcSize comment, above.
406
+ Enabled: false
407
+ Metrics/BlockNesting:
408
+ Enabled: true
409
+ Metrics/ClassLength:
410
+ # Disabled, see Metrics/AbcSize comment, above.
411
+ Enabled: false
412
+ Metrics/CyclomaticComplexity:
413
+ # Disabled as this cop seems arbitrary without some due-diligence on a max value that demonstrates
414
+ # an increase in quality, readability, maintainability or some other value.
415
+ Enabled: false
416
+ Metrics/MethodLength:
417
+ # Disabled, see Metrics/AbcSize comment, above.
418
+ Enabled: false
419
+ Metrics/ModuleLength:
420
+ # Disabled, see Metrics/AbcSize comment, above.
421
+ Enabled: false
422
+ Metrics/ParameterLists:
423
+ # Disabled, see Metrics/AbcSize comment, above.
424
+ Enabled: false
425
+ Metrics/PerceivedComplexity:
426
+ # Disabled, see Metrics/CyclomaticComplexity comment, above.
427
+ Enabled: false
428
+
429
+ # Naming Cop Configuration
430
+ # https://docs.rubocop.org/en/stable/cops_naming/
431
+
432
+ Naming/AccessorMethodName:
433
+ Enabled: true
434
+ Naming/AsciiIdentifiers:
435
+ Enabled: true
436
+ Naming/BinaryOperatorParameterName:
437
+ Enabled: true
438
+ Naming/BlockParameterName:
439
+ Enabled: true
440
+ Naming/ClassAndModuleCamelCase:
441
+ Enabled: true
442
+ Naming/ConstantName:
443
+ Enabled: true
444
+ Naming/FileName:
445
+ Enabled: true
446
+ Naming/HeredocDelimiterCase:
447
+ Enabled: true
448
+ Naming/HeredocDelimiterNaming:
449
+ Enabled: true
450
+ Naming/MemoizedInstanceVariableName:
451
+ Enabled: true
452
+ Naming/MethodName:
453
+ Enabled: true
454
+ IgnoredPatterns:
455
+ - 'do_GET'
456
+ - 'do_POST'
457
+ - 'do_PUT'
458
+ - 'do_DELETE'
459
+ - 'do_HEAD'
460
+ - 'do_OPTIONS'
461
+ Naming/MethodParameterName:
462
+ Enabled: true
463
+ Naming/PredicateName:
464
+ Enabled: true
465
+ Naming/RescuedExceptionsVariableName:
466
+ # Disabled. It's acceptable to use alternate variable names for rescued exceptions, when necessary.
467
+ Enabled: false
468
+ Naming/VariableName:
469
+ Enabled: true
470
+ Naming/VariableNumber:
471
+ Enabled: true
472
+
473
+
474
+ # Performance Cop Configuration
475
+ # https://rubocop-performance.readthedocs.io/en/stable/cops_performance/
476
+
477
+ Performance/Caller:
478
+ Enabled: true
479
+ Performance/CaseWhenSplat:
480
+ Enabled: true
481
+ Performance/Casecmp:
482
+ Enabled: true
483
+ Performance/ChainArrayAllocation:
484
+ Enabled: true
485
+ Performance/CompareWithBlock:
486
+ Enabled: true
487
+ Performance/Count:
488
+ Enabled: true
489
+ Performance/Detect:
490
+ Enabled: true
491
+ Performance/DoubleStartEndWith:
492
+ Enabled: true
493
+ Performance/EndWith:
494
+ Enabled: true
495
+ Performance/FixedSize:
496
+ Enabled: true
497
+ Performance/FlatMap:
498
+ Enabled: true
499
+ Performance/InefficientHashSearch:
500
+ Enabled: true
501
+ Performance/OpenStruct:
502
+ Enabled: true
503
+ Performance/RangeInclude:
504
+ Enabled: true
505
+ Performance/RedundantBlockCall:
506
+ Enabled: true
507
+ Performance/RedundantMatch:
508
+ Enabled: true
509
+ Performance/RedundantMerge:
510
+ Enabled: true
511
+ Performance/RegexpMatch:
512
+ Enabled: true
513
+ Performance/ReverseEach:
514
+ Enabled: true
515
+ Performance/Size:
516
+ Enabled: true
517
+ Performance/StartWith:
518
+ Enabled: true
519
+ Performance/StringReplacement:
520
+ Enabled: true
521
+ Performance/TimesMap:
522
+ Enabled: true
523
+ Performance/UnfreezeString:
524
+ Enabled: true
525
+ Performance/UriDefaultParser:
526
+ Enabled: true
527
+
528
+ # Security Cop Configuration
529
+ # https://docs.rubocop.org/en/stable/cops_security/
530
+
531
+ Security/Eval:
532
+ Enabled: true
533
+ Security/JSONLoad:
534
+ Enabled: true
535
+ Security/MarshalLoad:
536
+ Enabled: true
537
+ Security/Open:
538
+ Enabled: true
539
+ Security/YAMLLoad:
540
+ Enabled: true
541
+
542
+ # Style Cop Configuration
543
+ # https://docs.rubocop.org/en/stable/cops_style/
544
+
545
+ Style/AccessModifierDeclarations:
546
+ Enabled: true
547
+ Style/Alias:
548
+ Enabled: true
549
+ Style/AndOr:
550
+ Enabled: true
551
+ Style/ArrayJoin:
552
+ Enabled: true
553
+ Style/AsciiComments:
554
+ Enabled: true
555
+ Style/Attr:
556
+ Enabled: true
557
+ Style/AutoResourceCleanup:
558
+ Enabled: false
559
+ Style/BarePercentLiterals:
560
+ Enabled: true
561
+ Style/BeginBlock:
562
+ Enabled: true
563
+ Style/BlockComments:
564
+ Enabled: true
565
+ Style/BlockDelimiters:
566
+ Enabled: true
567
+ Style/CaseEquality:
568
+ Enabled: true
569
+ Style/CharacterLiteral:
570
+ Enabled: true
571
+ Style/ClassAndModuleChildren:
572
+ Enabled: true
573
+ Style/ClassCheck:
574
+ Enabled: true
575
+ Style/ClassMethods:
576
+ Enabled: true
577
+ Style/ClassVars:
578
+ Enabled: true
579
+ Style/CollectionMethods:
580
+ # Disabled. There is no preference on which collection method aliases should be used.
581
+ Enabled: false
582
+ Style/ColonMethodCall:
583
+ Enabled: true
584
+ Style/ColonMethodDefinition:
585
+ Enabled: true
586
+ Style/CommandLiteral:
587
+ Enabled: true
588
+ Style/CommentAnnotation:
589
+ Enabled: true
590
+ Style/CommentedKeyword:
591
+ Enabled: true
592
+ Style/ConditionalAssignment:
593
+ Enabled: true
594
+ Style/ConstantVisibility:
595
+ # Disabled. Most constants need to be public, so this provides little value.
596
+ Enabled: false
597
+ Style/Copyright:
598
+ # Disabled. Copyright statements are not required.
599
+ Enabled: false
600
+ Style/DateTime:
601
+ Enabled: true
602
+ Style/DefWithParentheses:
603
+ Enabled: true
604
+ Style/Dir:
605
+ Enabled: true
606
+ Style/Documentation:
607
+ Enabled: true
608
+ Exclude:
609
+ - test/**/*
610
+ - spec/**/*
611
+ Style/DocumentationMethod:
612
+ Enabled: true
613
+ Exclude:
614
+ - test/**/*
615
+ - spec/**/*
616
+ Style/DoubleCopDisableDirective:
617
+ Enabled: true
618
+ Style/DoubleNegation:
619
+ Enabled: true
620
+ Style/EachForSimpleLoop:
621
+ Enabled: true
622
+ Style/EachWithObject:
623
+ Enabled: true
624
+ Style/EmptyBlockParameter:
625
+ Enabled: true
626
+ Style/EmptyCaseCondition:
627
+ Enabled: true
628
+ Style/EmptyElse:
629
+ Enabled: true
630
+ Style/EmptyLambdaParameter:
631
+ Enabled: true
632
+ Style/EmptyLiteral:
633
+ Enabled: true
634
+ Style/EmptyMethod:
635
+ Enabled: true
636
+ Style/Encoding:
637
+ Enabled: true
638
+ Style/EndBlock:
639
+ Enabled: true
640
+ Style/EvalWithLocation:
641
+ Enabled: true
642
+ Style/EvenOdd:
643
+ Enabled: true
644
+ Style/ExpandPathArguments:
645
+ Enabled: true
646
+ Style/FloatDivision:
647
+ Enabled: true
648
+ Style/For:
649
+ Enabled: true
650
+ Style/FormatString:
651
+ Enabled: true
652
+ Style/FormatStringToken:
653
+ Enabled: true
654
+ Style/FrozenStringLiteralComment:
655
+ Enabled: true
656
+ Style/GlobalVars:
657
+ Enabled: true
658
+ Style/GuardClause:
659
+ Enabled: true
660
+ Style/HashSyntax:
661
+ Enabled: true
662
+ Style/IdenticalConditionalBranches:
663
+ Enabled: true
664
+ Style/IfInsideElse:
665
+ Enabled: true
666
+ Style/IfUnlessModifier:
667
+ Enabled: true
668
+ Style/IfUnlessModifierOfIfUnless:
669
+ Enabled: true
670
+ Style/IfWithSemicolon:
671
+ Enabled: true
672
+ Style/ImplicitRuntimeError:
673
+ # Enabled. It is preferred to avoid raising implicit exceptions; they should be explicitly declared.
674
+ Enabled: true
675
+ Style/InfiniteLoop:
676
+ Enabled: true
677
+ Style/InlineComment:
678
+ # Disabled. Inline comments are allowed.
679
+ Enabled: false
680
+ Style/InverseMethods:
681
+ # Disabled. Determining whether using select or reject is most appropriate is best left to the
682
+ # person writing the code.
683
+ Enabled: false
684
+ Style/IpAddresses:
685
+ # Enabled. This cop may potentially be problematic, but we'll attempt to maintain the whitelist
686
+ # until we encounter an issue.
687
+ Enabled: true
688
+ AllowedAddresses:
689
+ - '::'
690
+ - '::1'
691
+ - '127.0.0.1'
692
+ Style/Lambda:
693
+ Enabled: true
694
+ Style/LambdaCall:
695
+ Enabled: true
696
+ Style/LineEndConcatenation:
697
+ Enabled: true
698
+ Style/MethodCallWithArgsParentheses:
699
+ # Disabled. It is acceptable to write argument bearing method invocations without parentheses in
700
+ # many cases.
701
+ Enabled: false
702
+ Style/MethodCallWithoutArgsParentheses:
703
+ Enabled: true
704
+ Style/MethodCalledOnDoEndBlock:
705
+ # Disabled. It is acceptable to call a method at the end of a do/end block. In particular, this is
706
+ # occationally needed in RSpec code.
707
+ Enabled: false
708
+ Style/MethodDefParentheses:
709
+ Enabled: true
710
+ Style/MinMax:
711
+ Enabled: true
712
+ Style/MissingElse:
713
+ # Disabled. It is acceptable for an if expression to not always have an else.
714
+ Enabled: false
715
+ Style/MissingRespondToMissing:
716
+ Enabled: true
717
+ Style/MixinGrouping:
718
+ Enabled: true
719
+ Style/MixinUsage:
720
+ Enabled: true
721
+ Style/ModuleFunction:
722
+ Enabled: true
723
+ Style/MultilineBlockChain:
724
+ Enabled: true
725
+ Style/MultilineIfModifier:
726
+ Enabled: true
727
+ Style/MultilineIfThen:
728
+ Enabled: true
729
+ Style/MultilineMemoization:
730
+ Enabled: true
731
+ Style/MultilineMethodSignature:
732
+ # Disabled. It is acceptable to have a multiple line method signature when names and variables get
733
+ # too long.
734
+ Enabled: false
735
+ Style/MultilineTernaryOperator:
736
+ Enabled: true
737
+ Style/MultilineWhenThen:
738
+ Enabled: true
739
+ Style/MultipleComparison:
740
+ Enabled: true
741
+ Style/MutableConstant:
742
+ Enabled: true
743
+ Style/NegatedIf:
744
+ Enabled: true
745
+ Style/NegatedUnless:
746
+ Enabled: true
747
+ Style/NegatedWhile:
748
+ Enabled: true
749
+ Style/NestedModifier:
750
+ Enabled: true
751
+ Style/NestedParenthesizedCalls:
752
+ Enabled: true
753
+ Style/NestedTernaryOperator:
754
+ Enabled: true
755
+ Style/Next:
756
+ # Disabled. Don't require the use of 'next' when conditionals are used within loops.
757
+ Enabled: false
758
+ Style/NilComparison:
759
+ Enabled: true
760
+ Style/NonNilCheck:
761
+ Enabled: true
762
+ Style/Not:
763
+ Enabled: true
764
+ Style/NumericLiteralPrefix:
765
+ Enabled: true
766
+ Style/NumericLiterals:
767
+ Enabled: true
768
+ Style/NumericPredicate:
769
+ Enabled: true
770
+ Style/OneLineConditional:
771
+ Enabled: true
772
+ Style/OptionHash:
773
+ # Disabled. It is acceptable to use a Hash variable named options, instead of keyword arguments.
774
+ Enabled: false
775
+ Style/OptionalArguments:
776
+ Enabled: true
777
+ Style/OrAssignment:
778
+ Enabled: true
779
+ Style/ParallelAssignment:
780
+ Enabled: true
781
+ Style/ParenthesesAroundCondition:
782
+ Enabled: true
783
+ Style/PercentLiteralDelimiters:
784
+ Enabled: true
785
+ Style/PercentQLiterals:
786
+ Enabled: true
787
+ Style/PerlBackrefs:
788
+ Enabled: true
789
+ Style/PreferredHashMethods:
790
+ Enabled: true
791
+ Style/Proc:
792
+ Enabled: true
793
+ Style/RaiseArgs:
794
+ Enabled: true
795
+ Style/RandomWithOffset:
796
+ Enabled: true
797
+ Style/RedundantBegin:
798
+ Enabled: true
799
+ Style/RedundantCapitalW:
800
+ Enabled: true
801
+ Style/RedundantCondition:
802
+ Enabled: true
803
+ Style/RedundantConditional:
804
+ Enabled: true
805
+ Style/RedundantException:
806
+ Enabled: true
807
+ Style/RedundantFreeze:
808
+ Enabled: true
809
+ Style/RedundantInterpolation:
810
+ Enabled: true
811
+ Style/RedundantParentheses:
812
+ Enabled: true
813
+ Style/RedundantPercentQ:
814
+ Enabled: true
815
+ Style/RedundantReturn:
816
+ Enabled: true
817
+ Style/RedundantSelf:
818
+ Enabled: true
819
+ Style/RedundantSort:
820
+ Enabled: true
821
+ Style/RedundantSortBy:
822
+ Enabled: true
823
+ Style/RegexpLiteral:
824
+ Enabled: true
825
+ EnforcedStyle: slashes
826
+ AllowInnerSlashes: true
827
+ Style/RescueModifier:
828
+ Enabled: true
829
+ Style/RescueStandardError:
830
+ Enabled: true
831
+ Style/ReturnNil:
832
+ # Enabled. It is preferred to omit the literal 'nil' when returning.
833
+ Enabled: true
834
+ EnforcedStyle: return
835
+ Style/SafeNavigation:
836
+ Enabled: true
837
+ Style/Sample:
838
+ Enabled: true
839
+ Style/SelfAssignment:
840
+ Enabled: true
841
+ Style/Semicolon:
842
+ Enabled: true
843
+ Style/Send:
844
+ # Disabled. Any form of send is acceptable.
845
+ Enabled: false
846
+ Style/SignalException:
847
+ Enabled: true
848
+ Style/SingleLineBlockParams:
849
+ # Disabled. This cop is problematic and the default values are overbearing.
850
+ Enabled: false
851
+ Style/SingleLineMethods:
852
+ Enabled: true
853
+ Style/SpecialGlobalVars:
854
+ Enabled: true
855
+ Style/StabbyLambdaParentheses:
856
+ Enabled: true
857
+ Style/StderrPuts:
858
+ # Disabled. This cop functionally equates use of STDERR with optional warnings. This may be true in some use cases, but there
859
+ # are times when using STDERR in CLIs is not an optional warning.
860
+ Enabled: false
861
+ Style/StringHashKeys:
862
+ # Disabled. There are many use cases where using Strings for Hash keys is required.
863
+ Enabled: false
864
+ Style/StringLiterals:
865
+ Enabled: true
866
+ Style/StringLiteralsInInterpolation:
867
+ Enabled: true
868
+ Style/StringMethods:
869
+ # Enabled. It is preferred to use 'to_sym' instead of the alias 'intern'.
870
+ Enabled: true
871
+ Style/Strip:
872
+ Enabled: true
873
+ Style/StructInheritance:
874
+ Enabled: true
875
+ Style/SymbolArray:
876
+ # Use of %i[] or %I[] can help readability and maintainability, but not necessarily for small
877
+ # arrays, which the manual defines as less than 7.
878
+ Enabled: true
879
+ MinSize: 7
880
+ Style/SymbolLiteral:
881
+ Enabled: true
882
+ Style/SymbolProc:
883
+ # Disabled. Using &:method, instead of { |obj| obj.method }, is sometimes more readable, there
884
+ # are plenty of cases when this is not the case.
885
+ Enabled: false
886
+ Style/TernaryParentheses:
887
+ Enabled: true
888
+ Style/TrailingBodyOnClass:
889
+ Enabled: true
890
+ Style/TrailingBodyOnMethodDefinition:
891
+ Enabled: true
892
+ Style/TrailingBodyOnModule:
893
+ Enabled: true
894
+ Style/TrailingCommaInArguments:
895
+ Enabled: true
896
+ Style/TrailingCommaInArrayLiteral:
897
+ Enabled: true
898
+ Style/TrailingCommaInHashLiteral:
899
+ Enabled: true
900
+ Style/TrailingMethodEndStatement:
901
+ Enabled: true
902
+ Style/TrailingUnderscoreVariable:
903
+ Enabled: true
904
+ Style/TrivialAccessors:
905
+ Enabled: true
906
+ Style/UnlessElse:
907
+ Enabled: true
908
+ Style/UnpackFirst:
909
+ Enabled: true
910
+ Style/VariableInterpolation:
911
+ Enabled: true
912
+ Style/WhenThen:
913
+ Enabled: true
914
+ Style/WhileUntilDo:
915
+ Enabled: true
916
+ Style/WhileUntilModifier:
917
+ Enabled: true
918
+ Style/WordArray:
919
+ # Use of %w[] or %W[] can help readability and maintainability, but not necessarily for small
920
+ # arrays, which the manual defines as less than 7.
921
+ Enabled: true
922
+ MinSize: 7
923
+ Style/YodaCondition:
924
+ Enabled: true
925
+ Style/ZeroLengthPredicate:
926
+ Enabled: true