spicerack-styleguide 0.24.0 → 0.25.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2a6355b170813d7069a7b6a0e6fafdd1fa7afa5647219b9d7246d6a73ef96f9f
4
- data.tar.gz: 1fb4555361aea6d8333101d755b154ba742196be2f8da1dec71ae77615a56131
3
+ metadata.gz: 2c8974271e821bb9d48c91aa9e872c354ab3dbab4f62b3e31c6493e8499d8b06
4
+ data.tar.gz: c1caeeb0f14049250306b8c6ac24e374959110caf236fc0bd1d174e3901d741e
5
5
  SHA512:
6
- metadata.gz: 854cae0d84f50d4e7bf0e3b8a7747d15250fe0c3f125ef67290d64685af40b1bf7c1c79ae1ab1a96d8d959d307e41121381e4682ca25ffe96dc768ed7c9eacc7
7
- data.tar.gz: d5c7a50d5efec53237ed5cebee8a374562a293358f191aac7e7db41fcf0bd3147ad6c2bbfefda0ffd3bf28081c049da6ad9442f18a62209d3443ecfd5392fa55
6
+ metadata.gz: 32e28e93abf6c90de36d5da48b644f695a6524ccac9a09469bf7b2d0c20a6bfea5e77756e4a8f92ed57eff397391254e45bd8f8f09767b08746fa67f2443f166
7
+ data.tar.gz: 88ba5cfc131cc6c720a5d7ade32c1604dea5ab3a685930e2ab57b3edb94f853e2a0b112b1f3163d455ffcf16e99a1fbc30d107dd3176c30c4f3037b092bc4b6d
@@ -3,6 +3,6 @@
3
3
  module Spicerack
4
4
  module Styleguide
5
5
  # This constant is managed by spicerack
6
- VERSION = "0.24.0"
6
+ VERSION = "0.25.0"
7
7
  end
8
8
  end
@@ -16,16 +16,10 @@ AllCops:
16
16
  Layout/AccessModifierIndentation:
17
17
  Enabled: true
18
18
  EnforcedStyle: indent
19
- Layout/AlignArray:
19
+ Layout/ArrayAlignment:
20
20
  Enabled: true
21
- Layout/AlignHash:
22
- Enabled: true
23
- EnforcedHashRocketStyle: key
24
- EnforcedColonStyle: key
25
- EnforcedLastArgumentHashStyle: always_inspect
26
- Layout/AlignParameters:
27
- Enabled: true
28
- EnforcedStyle: with_first_parameter
21
+ Layout/AssignmentIndentation:
22
+ Enabled: false
29
23
  Layout/BlockAlignment:
30
24
  Enabled: true
31
25
  EnforcedStyleAlignWith: start_of_block
@@ -77,6 +71,8 @@ Layout/EmptyLinesAroundAccessModifier:
77
71
  EnforcedStyle: around
78
72
  Layout/EmptyLinesAroundArguments:
79
73
  Enabled: true
74
+ Layout/EmptyLinesAroundAttributeAccessor:
75
+ Enabled: true
80
76
  Layout/EmptyLinesAroundBeginBody:
81
77
  Enabled: true
82
78
  Layout/EmptyLinesAroundBlockBody:
@@ -104,36 +100,40 @@ Layout/ExtraSpacing:
104
100
  ForceEqualSignAlignment: false
105
101
  Exclude:
106
102
  - "**/*.gemspec"
103
+ Layout/FirstArgumentIndentation:
104
+ Enabled: true
105
+ Layout/FirstArrayElementIndentation:
106
+ Enabled: true
107
+ EnforcedStyle: consistent
107
108
  Layout/FirstArrayElementLineBreak:
108
109
  Enabled: false
110
+ Layout/FirstHashElementIndentation:
111
+ Enabled: true
112
+ EnforcedStyle: consistent
109
113
  Layout/FirstHashElementLineBreak:
110
114
  Enabled: false
111
115
  Layout/FirstMethodArgumentLineBreak:
112
116
  Enabled: true
113
117
  Layout/FirstMethodParameterLineBreak:
114
118
  Enabled: true
115
- Layout/HeredocArgumentClosingParenthesis:
116
- Enabled: true
117
- Lint/HeredocMethodCallPosition:
118
- Enabled: true
119
- Layout/IndentAssignment:
120
- Enabled: false
121
- Layout/IndentFirstArgument:
119
+ Layout/FirstParameterIndentation:
122
120
  Enabled: true
123
- Layout/IndentFirstArrayElement:
121
+ Layout/HashAlignment:
124
122
  Enabled: true
125
- EnforcedStyle: consistent
126
- Layout/IndentFirstHashElement:
123
+ EnforcedHashRocketStyle: key
124
+ EnforcedColonStyle: key
125
+ EnforcedLastArgumentHashStyle: always_inspect
126
+ Layout/HeredocArgumentClosingParenthesis:
127
127
  Enabled: true
128
- EnforcedStyle: consistent
129
- Layout/IndentFirstParameter:
128
+ Layout/HeredocIndentation:
130
129
  Enabled: true
131
- Layout/IndentHeredoc:
130
+ Lint/HeredocMethodCallPosition:
132
131
  Enabled: true
133
- EnforcedStyle: squiggly
134
132
  Layout/IndentationConsistency:
135
133
  Enabled: true
136
134
  EnforcedStyle: normal
135
+ Layout/IndentationStyle:
136
+ Enabled: true
137
137
  Layout/IndentationWidth:
138
138
  Enabled: true
139
139
  Width: 2
@@ -141,6 +141,9 @@ Layout/InitialIndentation:
141
141
  Enabled: true
142
142
  Layout/LeadingCommentSpace:
143
143
  Enabled: true
144
+ Layout/LineLength:
145
+ Enabled: false
146
+ Max: 120
144
147
  Layout/MultilineArrayBraceLayout:
145
148
  Enabled: true
146
149
  EnforcedStyle: symmetrical
@@ -163,6 +166,9 @@ Layout/MultilineMethodDefinitionBraceLayout:
163
166
  Layout/MultilineOperationIndentation:
164
167
  Enabled: true
165
168
  EnforcedStyle: aligned
169
+ Layout/ParameterAlignment:
170
+ Enabled: true
171
+ EnforcedStyle: with_first_parameter
166
172
  Layout/RescueEnsureAlignment:
167
173
  Enabled: true
168
174
  Layout/SpaceAfterColon:
@@ -183,6 +189,8 @@ Layout/SpaceAroundEqualsInParameterDefault:
183
189
  EnforcedStyle: space
184
190
  Layout/SpaceAroundKeyword:
185
191
  Enabled: true
192
+ Layout/SpaceAroundMethodCallOperator:
193
+ Enabled: true
186
194
  Layout/SpaceAroundOperators:
187
195
  Enabled: true
188
196
  Layout/SpaceBeforeBlockBraces:
@@ -226,9 +234,7 @@ Layout/SpaceInsideReferenceBrackets:
226
234
  EnforcedStyleForEmptyBrackets: no_space
227
235
  Layout/SpaceInsideStringInterpolation:
228
236
  EnforcedStyle: no_space
229
- Layout/Tab:
230
- Enabled: true
231
- Layout/TrailingBlankLines:
237
+ Layout/TrailingEmptyLines:
232
238
  Enabled: true
233
239
  EnforcedStyle: final_newline
234
240
  Layout/TrailingWhitespace:
@@ -246,46 +252,61 @@ Lint/AssignmentInCondition:
246
252
  Enabled: true
247
253
  Lint/BigDecimalNew:
248
254
  Enabled: false
255
+ Lint/BinaryOperatorWithIdenticalOperands:
256
+ Enabled: true
249
257
  Lint/BooleanSymbol:
250
258
  Enabled: true
251
259
  Lint/CircularArgumentReference:
252
260
  Enabled: true
261
+ Lint/ConstantResolution:
262
+ Enabled: false
253
263
  Lint/DisjunctiveAssignmentInConstructor:
254
264
  Enabled: true
255
265
  Lint/Debugger:
256
266
  Enabled: true
257
267
  Lint/DeprecatedClassMethods:
258
268
  Enabled: true
269
+ Lint/DeprecatedOpenSSLConstant:
270
+ Enabled: true
259
271
  Lint/DuplicateCaseCondition:
260
272
  Enabled: true
273
+ Lint/DuplicateElsifCondition:
274
+ Enabled: true
275
+ Lint/DuplicateHashKey:
276
+ Enabled: true
261
277
  Lint/DuplicateMethods:
262
278
  Enabled: true
263
- Lint/DuplicatedKey:
279
+ Lint/DuplicateRequire:
280
+ Enabled: true
281
+ Lint/DuplicateRescueException:
264
282
  Enabled: true
265
283
  Lint/EachWithObjectArgument:
266
284
  Enabled: true
267
285
  Lint/ElseLayout:
268
286
  Enabled: true
287
+ Lint/EmptyConditionalBody:
288
+ Enabled: true
269
289
  Lint/EmptyEnsure:
270
290
  Enabled: true
271
291
  Lint/EmptyExpression:
272
292
  Enabled: true
293
+ Lint/EmptyFile:
294
+ Enabled: true
273
295
  Lint/EmptyInterpolation:
274
296
  Enabled: true
275
297
  Lint/EmptyWhen:
276
298
  Enabled: true
277
- Lint/EndInMethod:
278
- Enabled: true
299
+ AllowComments: true
279
300
  Lint/EnsureReturn:
280
301
  Enabled: true
281
302
  Lint/FlipFlop:
282
303
  Enabled: true
304
+ Lint/FloatComparison:
305
+ Enabled: true
283
306
  Lint/FloatOutOfRange:
284
307
  Enabled: true
285
308
  Lint/FormatParameterMismatch:
286
309
  Enabled: true
287
- Lint/HandleExceptions:
288
- Enabled: true
289
310
  Lint/ImplicitStringConcatenation:
290
311
  Enabled: true
291
312
  Lint/IneffectiveAccessModifier:
@@ -303,7 +324,11 @@ Lint/Loop:
303
324
  Enabled: true
304
325
  Lint/MissingCopEnableDirective:
305
326
  Enabled: true
306
- Lint/MultipleCompare:
327
+ Lint/MissingSuper:
328
+ Enabled: true
329
+ Lint/MixedRegexpCaptureTypes:
330
+ Enabled: true
331
+ Lint/MultipleComparison:
307
332
  Enabled: true
308
333
  Lint/NestedMethodDefinition:
309
334
  Enabled: true
@@ -311,12 +336,16 @@ Lint/NestedPercentLiteral:
311
336
  Enabled: true
312
337
  Lint/NextWithoutAccumulator:
313
338
  Enabled: true
339
+ Lint/NonDeterministicRequireOrder:
340
+ Enabled: true
314
341
  Lint/NonLocalExitFromIterator:
315
342
  Enabled: true
316
343
  Lint/NumberConversion:
317
344
  Enabled: false
318
345
  Lint/OrderedMagicComments:
319
346
  Enabled: true
347
+ Lint/OutOfRangeRegexpRef:
348
+ Enabled: true
320
349
  Lint/ParenthesesAsGroupedExpression:
321
350
  Enabled: true
322
351
  Lint/PercentStringArray:
@@ -325,6 +354,8 @@ Lint/PercentSymbolArray:
325
354
  Enabled: true
326
355
  Lint/RandOne:
327
356
  Enabled: true
357
+ Lint/RedundantStringCoercion:
358
+ Enabled: true
328
359
  Lint/RedundantWithIndex:
329
360
  Enabled: true
330
361
  Lint/RedundantWithObject:
@@ -345,13 +376,17 @@ Lint/SafeNavigationWithEmpty:
345
376
  Enabled: true
346
377
  Lint/ScriptPermission:
347
378
  Enabled: true
379
+ Lint/SendWithMixinArgument:
380
+ Enabled: true
348
381
  Lint/ShadowedArgument:
349
382
  Enabled: true
350
383
  Lint/ShadowedException:
351
384
  Enabled: true
352
385
  Lint/ShadowingOuterLocalVariable:
353
386
  Enabled: true
354
- Lint/StringConversionInInterpolation:
387
+ Lint/StructNewOverride:
388
+ Enabled: true
389
+ Lint/SuppressedException:
355
390
  Enabled: true
356
391
  Lint/ToJSON:
357
392
  Enabled: true
@@ -359,16 +394,26 @@ Lint/UnderscorePrefixedVariableName:
359
394
  Enabled: true
360
395
  Lint/UnifiedInteger:
361
396
  Enabled: true
362
- Lint/UnneededCopDisableDirective:
397
+ Lint/RaiseException:
398
+ Enabled: true
399
+ Lint/RedundantCopDisableDirective:
400
+ Enabled: true
401
+ Lint/RedundantCopEnableDirective:
402
+ Enabled: true
403
+ Lint/RedundantRequireStatement:
363
404
  Enabled: true
364
- Lint/UnneededCopEnableDirective:
405
+ Lint/RedundantSplatExpansion:
365
406
  Enabled: true
366
- Lint/UnneededRequireStatement:
407
+ Lint/SelfAssignment:
367
408
  Enabled: true
368
- Lint/UnneededSplatExpansion:
409
+ Lint/TopLevelReturnWithArgument:
410
+ Enabled: true
411
+ Lint/TrailingCommaInAttributeDeclaration:
369
412
  Enabled: true
370
413
  Lint/UnreachableCode:
371
414
  Enabled: true
415
+ Lint/UnreachableLoop:
416
+ Enabled: true
372
417
  Lint/UnusedBlockArgument:
373
418
  Enabled: true
374
419
  Lint/UnusedMethodArgument:
@@ -381,10 +426,10 @@ Lint/UselessAccessModifier:
381
426
  Enabled: true
382
427
  Lint/UselessAssignment:
383
428
  Enabled: true
384
- Lint/UselessComparison:
385
- Enabled: true
386
429
  Lint/UselessElseWithoutRescue:
387
430
  Enabled: true
431
+ Lint/UselessMethodDefinition:
432
+ Enabled: true
388
433
  Lint/UselessSetterCall:
389
434
  Enabled: true
390
435
  Lint/Void:
@@ -414,9 +459,6 @@ Metrics/ClassLength:
414
459
  Metrics/CyclomaticComplexity:
415
460
  Enabled: true
416
461
  Max: 6
417
- Metrics/LineLength:
418
- Enabled: false
419
- Max: 120
420
462
  Metrics/MethodLength:
421
463
  Enabled: true
422
464
  Max: 24
@@ -436,6 +478,10 @@ Naming/AsciiIdentifiers:
436
478
  Enabled: true
437
479
  Naming/BinaryOperatorParameterName:
438
480
  Enabled: true
481
+ Naming/BlockParameterName:
482
+ Enabled: true
483
+ MinNameLength: 1
484
+ AllowNamesEndingInNumbers: true
439
485
  Naming/ClassAndModuleCamelCase:
440
486
  Enabled: true
441
487
  Naming/ConstantName:
@@ -452,17 +498,31 @@ Naming/MemoizedInstanceVariableName:
452
498
  Naming/MethodName:
453
499
  Enabled: true
454
500
  EnforcedStyle: snake_case
501
+ Naming/MethodParameterName:
502
+ Enabled: true
503
+ MinNameLength: 2
504
+ AllowNamesEndingInNumbers: true
505
+ AllowedNames:
506
+ - a
507
+ - b
508
+ - io
509
+ - id
510
+ - to
511
+ - by
512
+ - on
513
+ - in
514
+ - at
455
515
  Naming/PredicateName:
456
516
  Enabled: true
457
517
  NamePrefix:
458
518
  - is_
459
519
  - has_
460
520
  - have_
461
- NamePrefixBlacklist:
521
+ ForbiddenPrefixes:
462
522
  - is_
463
523
  - has_
464
524
  - have_
465
- NameWhitelist:
525
+ AllowedMethods:
466
526
  - is_a?
467
527
  MethodDefinitionMacros:
468
528
  - define_method
@@ -473,24 +533,6 @@ Naming/PredicateName:
473
533
  Naming/RescuedExceptionsVariableName:
474
534
  Enabled: true
475
535
  PreferredName: exception
476
- Naming/UncommunicativeBlockParamName:
477
- Enabled: true
478
- MinNameLength: 1
479
- AllowNamesEndingInNumbers: true
480
- Naming/UncommunicativeMethodParamName:
481
- Enabled: true
482
- MinNameLength: 2
483
- AllowNamesEndingInNumbers: true
484
- AllowedNames:
485
- - a
486
- - b
487
- - io
488
- - id
489
- - to
490
- - by
491
- - on
492
- - in
493
- - at
494
536
  Naming/VariableName:
495
537
  Enabled: true
496
538
  EnforcedStyle: snake_case
@@ -498,12 +540,18 @@ Naming/VariableNumber:
498
540
  Enabled: true
499
541
  EnforcedStyle: normalcase
500
542
 
543
+ Performance/AncestorsInclude:
544
+ Enabled: false
545
+ Performance/BigDecimalWithNumericArgument:
546
+ Enabled: false
501
547
  Performance/Caller:
502
548
  Enabled: false
503
549
  Performance/CaseWhenSplat:
504
550
  Enabled: true
505
551
  Performance/Casecmp:
506
552
  Enabled: true
553
+ Performance/CollectionLiteralInLoop:
554
+ Enabled: true
507
555
  Performance/CompareWithBlock:
508
556
  Enabled: true
509
557
  Performance/Count:
@@ -518,6 +566,8 @@ Performance/FixedSize:
518
566
  Enabled: true
519
567
  Performance/FlatMap:
520
568
  Enabled: true
569
+ Performance/IoReadlines:
570
+ Enabled: true
521
571
  Performance/OpenStruct:
522
572
  Enabled: true
523
573
  Exclude:
@@ -530,44 +580,71 @@ Performance/RedundantMatch:
530
580
  Enabled: true
531
581
  Performance/RedundantMerge:
532
582
  Enabled: true
583
+ Performance/RedundantSortBlock:
584
+ Enabled: true
585
+ Performance/RedundantStringChars:
586
+ Enabled: true
533
587
  Performance/RegexpMatch:
534
588
  Enabled: true
535
589
  Performance/ReverseEach:
536
590
  Enabled: true
591
+ Performance/ReverseFirst:
592
+ Enabled: true
537
593
  Performance/Size:
538
594
  Enabled: true
595
+ Performance/SortReverse:
596
+ Enabled: true
597
+ Performance/Squeeze:
598
+ Enabled: true
539
599
  Performance/StartWith:
540
600
  Enabled: true
601
+ Performance/StringInclude:
602
+ Enabled: true
541
603
  Performance/StringReplacement:
542
604
  Enabled: true
605
+ Performance/Sum:
606
+ Enabled: true
543
607
  Performance/TimesMap:
544
608
  Enabled: true
545
609
  Performance/UnfreezeString:
546
610
  Enabled: true
547
611
  Performance/UriDefaultParser:
548
612
  Enabled: true
613
+
549
614
  Rails/ActionFilter:
550
615
  Enabled: true
551
616
  EnforcedStyle: action
552
617
  Rails/ActiveRecordAliases:
553
618
  Enabled: true
619
+ Rails/ActiveRecordCallbacksOrder:
620
+ Enabled: true
554
621
  Rails/ActiveRecordOverride:
555
622
  Enabled: true
556
623
  Rails/ActiveSupportAliases:
557
624
  Enabled: true
625
+ Rails/ApplicationController:
626
+ Enabled: true
627
+ Rails/ApplicationMailer:
628
+ Enabled: true
558
629
  Rails/ApplicationJob:
559
630
  Enabled: true
560
631
  Rails/ApplicationRecord:
561
632
  Enabled: true
633
+ Rails/AfterCommitOverride:
634
+ Enabled: true
562
635
  Rails/BelongsTo:
563
636
  Enabled: true
564
637
  Rails/Blank:
565
638
  Enabled: true
639
+ Rails/ContentTag:
640
+ Enabled: true
566
641
  Rails/CreateTableWithTimestamps:
567
642
  Enabled: true
568
643
  Rails/Date:
569
644
  Enabled: true
570
645
  EnforcedStyle: flexible
646
+ Rails/DefaultScope:
647
+ Enabled: true
571
648
  Rails/Delegate:
572
649
  Enabled: true
573
650
  Rails/DelegateAllowBlank:
@@ -589,6 +666,8 @@ Rails/FindBy:
589
666
  Enabled: true
590
667
  Include:
591
668
  - app/models/**/*.rb
669
+ Rails/FindById:
670
+ Enabled: true
592
671
  Rails/FindEach:
593
672
  Enabled: true
594
673
  Include:
@@ -608,8 +687,14 @@ Rails/HttpPositionalArguments:
608
687
  Rails/HttpStatus:
609
688
  Enabled: true
610
689
  EnforcedStyle: symbolic
690
+ Rails/IndexBy:
691
+ Enabled: true
692
+ Rails/IndexWith:
693
+ Enabled: true
611
694
  Rails/IgnoredSkipActionFilterOption:
612
695
  Enabled: true
696
+ Rails/Inquiry:
697
+ Enabled: true
613
698
  Rails/InverseOf:
614
699
  Enabled: true
615
700
  Include:
@@ -620,10 +705,18 @@ Rails/LexicallyScopedActionFilter:
620
705
  - app/controllers/**/*.rb
621
706
  Rails/LinkToBlank:
622
707
  Enabled: true
708
+ Rails/MailerName:
709
+ Enabled: true
710
+ Rails/MatchRoute:
711
+ Enabled: true
712
+ Rails/NegateInclude:
713
+ Enabled: true
623
714
  Rails/NotNullColumn:
624
715
  Enabled: true
625
716
  Include:
626
717
  - db/migrate/*.rb
718
+ Rails/OrderById:
719
+ Enabled: true
627
720
  Rails/Output:
628
721
  Enabled: true
629
722
  Include:
@@ -633,6 +726,14 @@ Rails/Output:
633
726
  - lib/**/*.rb
634
727
  Rails/OutputSafety:
635
728
  Enabled: true
729
+ Rails/Pick:
730
+ Enabled: true
731
+ Rails/Pluck:
732
+ Enabled: true
733
+ Rails/PluckId:
734
+ Enabled: true
735
+ Rails/PluckInWhere:
736
+ Enabled: true
636
737
  Rails/PluralizationGrammar:
637
738
  Enabled: true
638
739
  Rails/Presence:
@@ -642,18 +743,28 @@ Rails/Present:
642
743
  NotNilAndNotEmpty: true
643
744
  NotBlank: true
644
745
  UnlessBlank: true
746
+ Rails/RakeEnvironment:
747
+ Enabled: true
645
748
  Rails/ReadWriteAttribute:
646
749
  Enabled: true
647
750
  Include:
648
751
  - app/models/**/*.rb
649
752
  Rails/RedundantAllowNil:
650
753
  Enabled: true
754
+ Rails/RedundantForeignKey:
755
+ Enabled: true
651
756
  Rails/RedundantReceiverInWithOptions:
652
757
  Enabled: true
653
758
  Rails/ReflectionClassName:
654
759
  Enabled: true
760
+ Rails/RefuteMethods:
761
+ Enabled: true
655
762
  Rails/RelativeDateConstant:
656
763
  Enabled: true
764
+ Rails/RenderInline:
765
+ Enabled: true
766
+ Rails/RenderPlainText:
767
+ Enabled: true
657
768
  Rails/RequestReferer:
658
769
  Enabled: true
659
770
  EnforcedStyle: referer
@@ -663,15 +774,19 @@ Rails/ReversibleMigration:
663
774
  - db/migrate/*.rb
664
775
  Rails/SafeNavigation:
665
776
  Enabled: true
777
+ Rails/SafeNavigationWithBlank:
778
+ Enabled: true
666
779
  Rails/SaveBang:
667
780
  Enabled: true
668
781
  Rails/ScopeArgs:
669
782
  Enabled: true
670
783
  Include:
671
784
  - app/models/**/*.rb
785
+ Rails/ShortI18n:
786
+ Enabled: true
672
787
  Rails/SkipsModelValidations:
673
788
  Enabled: true
674
- Blacklist:
789
+ ForbiddenMethods:
675
790
  - decrement!
676
791
  - decrement_counter
677
792
  - increment!
@@ -683,18 +798,26 @@ Rails/SkipsModelValidations:
683
798
  - update_column
684
799
  - update_columns
685
800
  - update_counters
801
+ Rails/SquishedSQLHeredocs:
802
+ Enabled: true
686
803
  Rails/TimeZone:
687
804
  Enabled: true
688
805
  EnforcedStyle: flexible
689
806
  Rails/UniqBeforePluck:
690
807
  Enabled: true
691
808
  EnforcedStyle: conservative
809
+ Rails/UniqueValidationWithoutIndex:
810
+ Enabled: true
692
811
  Rails/UnknownEnv:
693
812
  Enabled: true
694
813
  Environments:
695
814
  - development
696
815
  - test
697
816
  - production
817
+ Rails/WhereExists:
818
+ Enabled: true
819
+ Rails/WhereNot:
820
+ Enabled: true
698
821
  Rails/Validation:
699
822
  Enabled: true
700
823
  Include:
@@ -711,12 +834,16 @@ Security/Open:
711
834
  Security/YAMLLoad:
712
835
  Enabled: true
713
836
 
837
+ Style/AccessorGrouping:
838
+ Enabled: true
714
839
  Style/Alias:
715
840
  Enabled: true
716
841
  EnforcedStyle: prefer_alias_method
717
842
  Style/AndOr:
718
843
  Enabled: true
719
844
  EnforcedStyle: conditionals
845
+ Style/ArrayCoercion:
846
+ Enabled: true
720
847
  Style/ArrayJoin:
721
848
  Enabled: true
722
849
  Style/AsciiComments:
@@ -730,16 +857,17 @@ Style/BarePercentLiterals:
730
857
  EnforcedStyle: bare_percent
731
858
  Style/BeginBlock:
732
859
  Enabled: true
860
+ Style/BisectedAttrAccessor:
861
+ Enabled: true
733
862
  Style/BlockComments:
734
863
  Enabled: true
735
864
  Style/BlockDelimiters:
736
865
  Enabled: true
737
866
  EnforcedStyle: line_count_based
738
- Style/BracesAroundHashParameters:
739
- Enabled: true
740
- EnforcedStyle: context_dependent
741
867
  Style/CaseEquality:
742
868
  Enabled: true
869
+ Style/CaseLikeIf:
870
+ Enabled: true
743
871
  Style/CharacterLiteral:
744
872
  Enabled: true
745
873
  Style/ClassAndModuleChildren:
@@ -750,6 +878,9 @@ Style/ClassCheck:
750
878
  EnforcedStyle: is_a?
751
879
  Style/ClassMethods:
752
880
  Enabled: true
881
+ Style/ClassMethodsDefinitions:
882
+ Enabled: true
883
+ EnforcedStyle: self_class
753
884
  Style/ClassVars:
754
885
  Enabled: true
755
886
  Style/CollectionMethods:
@@ -758,6 +889,8 @@ Style/ColonMethodCall:
758
889
  Enabled: true
759
890
  Style/ColonMethodDefinition:
760
891
  Enabled: true
892
+ Style/CombinableLoops:
893
+ Enabled: true
761
894
  Style/CommandLiteral:
762
895
  Enabled: false
763
896
  Style/CommentAnnotation:
@@ -785,6 +918,8 @@ Style/DefWithParentheses:
785
918
  Enabled: true
786
919
  Style/Dir:
787
920
  Enabled: true
921
+ Style/DisableCopsWithinSourceCodeDirective:
922
+ Enabled: false
788
923
  Style/Documentation:
789
924
  Enabled: false
790
925
  Style/DocumentationMethod:
@@ -806,6 +941,8 @@ Style/EmptyLambdaParameter:
806
941
  Enabled: true
807
942
  Layout/EmptyLineAfterGuardClause:
808
943
  Enabled: true
944
+ Layout/EmptyLineAfterMultilineCondition:
945
+ Enabled: true
809
946
  Style/EmptyLiteral:
810
947
  Enabled: true
811
948
  Style/EmptyMethod:
@@ -821,6 +958,10 @@ Style/EvenOdd:
821
958
  Enabled: true
822
959
  Style/ExpandPathArguments:
823
960
  Enabled: true
961
+ Style/ExplicitBlockArgument:
962
+ Enabled: true
963
+ Style/ExponentialNotation:
964
+ Enabled: true
824
965
  Style/FloatDivision:
825
966
  Enabled: true
826
967
  Style/For:
@@ -834,17 +975,29 @@ Style/FormatStringToken:
834
975
  EnforcedStyle: template
835
976
  Style/FrozenStringLiteralComment:
836
977
  Enabled: true
837
- EnforcedStyle: always
978
+ EnforcedStyle: always_true
979
+ Style/GlobalStdStream:
980
+ Enabled: true
838
981
  Style/GlobalVars:
839
982
  Enabled: true
840
983
  Style/GuardClause:
841
984
  Enabled: true
842
985
  MinBodyLength: 1
986
+ Style/HashAsLastArrayItem:
987
+ Enabled: true
988
+ Style/HashEachMethods:
989
+ Enabled: true
990
+ Style/HashLikeCase:
991
+ Enabled: true
843
992
  Style/HashSyntax:
844
993
  Enabled: true
845
994
  EnforcedStyle: ruby19_no_mixed_keys
846
995
  UseHashRocketsWithSymbolValues: false
847
996
  PreferHashRocketsForNonAlnumEndingSymbols: false
997
+ Style/HashTransformKeys:
998
+ Enabled: true
999
+ Style/HashTransformValues:
1000
+ Enabled: true
848
1001
  Style/IdenticalConditionalBranches:
849
1002
  Enabled: true
850
1003
  Style/IfInsideElse:
@@ -863,6 +1016,8 @@ Style/InlineComment:
863
1016
  Enabled: true
864
1017
  Style/InverseMethods:
865
1018
  Enabled: true
1019
+ Style/KeywordParametersOrder:
1020
+ Enabled: true
866
1021
  Style/Lambda:
867
1022
  Enabled: true
868
1023
  EnforcedStyle: line_count_dependent
@@ -896,8 +1051,6 @@ Style/MultilineBlockChain:
896
1051
  Enabled: true
897
1052
  Style/MultilineIfModifier:
898
1053
  Enabled: true
899
- Style/MethodMissingSuper:
900
- Enabled: true
901
1054
  Style/MissingRespondToMissing:
902
1055
  Enabled: true
903
1056
  Style/MultilineIfThen:
@@ -925,7 +1078,7 @@ Style/NestedModifier:
925
1078
  Enabled: true
926
1079
  Style/NestedParenthesizedCalls:
927
1080
  Enabled: true
928
- Whitelist:
1081
+ AllowedMethods:
929
1082
  - be
930
1083
  - be_a
931
1084
  - be_an
@@ -977,6 +1130,8 @@ Style/OptionHash:
977
1130
  - parameters
978
1131
  Style/OptionalArguments:
979
1132
  Enabled: true
1133
+ Style/OptionalBooleanParameter:
1134
+ Enabled: true
980
1135
  Style/OrAssignment:
981
1136
  Enabled: true
982
1137
  Style/ParallelAssignment:
@@ -1001,21 +1156,33 @@ Style/RaiseArgs:
1001
1156
  EnforcedStyle: exploded
1002
1157
  Style/RandomWithOffset:
1003
1158
  Enabled: true
1159
+ Style/RedundantAssignment:
1160
+ Enabled: true
1004
1161
  Style/RedundantBegin:
1005
1162
  Enabled: true
1006
1163
  Style/RedundantConditional:
1007
1164
  Enabled: true
1008
1165
  Style/RedundantException:
1009
1166
  Enabled: false
1167
+ Style/RedundantFetchBlock:
1168
+ Enabled: true
1169
+ Style/RedundantFileExtensionInRequire:
1170
+ Enabled: true
1010
1171
  Style/RedundantFreeze:
1011
1172
  Enabled: true
1012
1173
  Style/RedundantParentheses:
1013
1174
  Enabled: true
1175
+ Style/RedundantRegexpCharacterClass:
1176
+ Enabled: true
1177
+ Style/RedundantRegexpEscape:
1178
+ Enabled: true
1014
1179
  Style/RedundantReturn:
1015
1180
  Enabled: true
1016
1181
  AllowMultipleReturnValues: false
1017
1182
  Style/RedundantSelf:
1018
1183
  Enabled: true
1184
+ Style/RedundantSelfAssignment:
1185
+ Enabled: true
1019
1186
  Style/RedundantSortBy:
1020
1187
  Enabled: true
1021
1188
  Style/RegexpLiteral:
@@ -1033,7 +1200,7 @@ Style/ReturnNil:
1033
1200
  Style/SafeNavigation:
1034
1201
  Enabled: true
1035
1202
  ConvertCodeThatCanStartToReturnNil: true
1036
- Whitelist:
1203
+ AllowedMethods:
1037
1204
  - present?
1038
1205
  - blank?
1039
1206
  - presence
@@ -1051,11 +1218,17 @@ Style/Send:
1051
1218
  Style/SignalException:
1052
1219
  Enabled: true
1053
1220
  EnforcedStyle: only_raise
1221
+ Style/SingleArgumentDig:
1222
+ Enabled: true
1054
1223
  Style/SingleLineBlockParams:
1055
1224
  Enabled: true
1056
1225
  Style/SingleLineMethods:
1057
1226
  Enabled: true
1058
1227
  AllowIfMethodIsEmpty: true
1228
+ Style/SlicingWithRange:
1229
+ Enabled: true
1230
+ Style/SoleNestedConditional:
1231
+ Enabled: true
1059
1232
  Style/SpecialGlobalVars:
1060
1233
  Enabled: true
1061
1234
  EnforcedStyle: use_english_names
@@ -1064,6 +1237,8 @@ Style/StabbyLambdaParentheses:
1064
1237
  EnforcedStyle: require_parentheses
1065
1238
  Style/StderrPuts:
1066
1239
  Enabled: true
1240
+ Style/StringConcatenation:
1241
+ Enabled: true
1067
1242
  Style/StringHashKeys:
1068
1243
  Enabled: true
1069
1244
  Style/StringLiterals:
@@ -1103,6 +1278,8 @@ Style/TrailingCommaInArguments:
1103
1278
  Style/TrailingCommaInArrayLiteral:
1104
1279
  Enabled: true
1105
1280
  EnforcedStyleForMultiline: comma
1281
+ Style/TrailingCommaInBlockArgs:
1282
+ Enabled: false
1106
1283
  Style/TrailingCommaInHashLiteral:
1107
1284
  Enabled: true
1108
1285
  EnforcedStyleForMultiline: comma
@@ -1116,7 +1293,7 @@ Style/TrivialAccessors:
1116
1293
  AllowPredicates: true
1117
1294
  AllowDSLWriters: false
1118
1295
  IgnoreClassMethods: false
1119
- Whitelist:
1296
+ AllowedMethods:
1120
1297
  - to_ary
1121
1298
  - to_a
1122
1299
  - to_c
@@ -1136,13 +1313,13 @@ Style/TrivialAccessors:
1136
1313
  - to_sym
1137
1314
  Style/UnlessElse:
1138
1315
  Enabled: true
1139
- Style/UnneededCapitalW:
1316
+ Style/RedundantCapitalW:
1140
1317
  Enabled: true
1141
- Style/UnneededInterpolation:
1318
+ Style/RedundantInterpolation:
1142
1319
  Enabled: true
1143
- Style/UnneededPercentQ:
1320
+ Style/RedundantPercentQ:
1144
1321
  Enabled: true
1145
- Style/UnneededSort:
1322
+ Style/RedundantSort:
1146
1323
  Enabled: true
1147
1324
  Style/UnpackFirst:
1148
1325
  Enabled: true
@@ -1207,8 +1384,14 @@ RSpec/DescribedClass:
1207
1384
  EnforcedStyle: described_class
1208
1385
  RSpec/Dialect:
1209
1386
  Enabled: false
1387
+ RSpec/ContextMethod:
1388
+ Enabled: true
1210
1389
  RSpec/EmptyExampleGroup:
1211
1390
  Enabled: true
1391
+ RSpec/EmptyHook:
1392
+ Enabled: true
1393
+ RSpec/EmptyLineAfterExample:
1394
+ Enabled: true
1212
1395
  RSpec/EmptyLineAfterFinalLet:
1213
1396
  Enabled: true
1214
1397
  RSpec/EmptyLineAfterSubject:
@@ -1278,6 +1461,8 @@ RSpec/MultipleDescribes:
1278
1461
  Enabled: true
1279
1462
  RSpec/MultipleExpectations:
1280
1463
  Enabled: false
1464
+ RSpec/MultipleMemoizedHelpers:
1465
+ Enabled: true
1281
1466
  RSpec/MultipleSubjects:
1282
1467
  Enabled: true
1283
1468
  RSpec/NamedSubject:
@@ -1300,6 +1485,10 @@ RSpec/RepeatedDescription:
1300
1485
  Enabled: true
1301
1486
  RSpec/RepeatedExample:
1302
1487
  Enabled: true
1488
+ RSpec/RepeatedExampleGroupBody:
1489
+ Enabled: true
1490
+ RSpec/RepeatedExampleGroupDescription:
1491
+ Enabled: true
1303
1492
  RSpec/ReturnFromStub:
1304
1493
  Enabled: true
1305
1494
  EnforcedStyle: and_return
@@ -1315,6 +1504,10 @@ RSpec/SingleArgumentMessageChain:
1315
1504
  Enabled: true
1316
1505
  RSpec/SubjectStub:
1317
1506
  Enabled: true
1507
+ RSpec/VariableDefinition:
1508
+ Enabled: true
1509
+ RSpec/VariableName:
1510
+ Enabled: true
1318
1511
  RSpec/VerifiedDoubles:
1319
1512
  Enabled: true
1320
1513
  IgnoreSymbolicNames: false
@@ -1323,13 +1516,17 @@ RSpec/VoidExpect:
1323
1516
  RSpec/Yield:
1324
1517
  Enabled: true
1325
1518
 
1519
+ FactoryBot/AttributeDefinedStatically:
1520
+ Enabled: true
1326
1521
  FactoryBot/CreateList:
1327
1522
  Enabled: true
1328
1523
  EnforcedStyle: create_list
1329
- FactoryBot/AttributeDefinedStatically:
1330
- Enabled: true
1524
+ FactoryBot/FactoryClassName:
1525
+ Enabled: true
1331
1526
 
1332
1527
  Capybara/CurrentPathExpectation:
1333
1528
  Enabled: true
1334
1529
  Capybara/FeatureMethods:
1335
1530
  Enabled: false
1531
+ Capybara/VisibilityMatcher:
1532
+ Enabled: true
metadata CHANGED
@@ -1,71 +1,71 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spicerack-styleguide
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.24.0
4
+ version: 0.25.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Allen Rettberg
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-28 00:00:00.000000000 Z
11
+ date: 2020-10-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '='
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0.74'
19
+ version: 0.90.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '='
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0.74'
26
+ version: 0.90.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rubocop-rspec
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '='
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.35.0
33
+ version: 1.43.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '='
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 1.35.0
40
+ version: 1.43.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubocop-performance
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '='
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 1.4.1
47
+ version: 1.8.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '='
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 1.4.1
54
+ version: 1.8.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rubocop-rails
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '='
59
+ - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 2.3.0
61
+ version: 2.8.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '='
66
+ - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 2.3.0
68
+ version: 2.8.0
69
69
  description: Wanna write code the Freshly way? Inherit this gem in your rubocop.yml
70
70
  and keep your code fresh
71
71
  email:
@@ -90,7 +90,7 @@ metadata:
90
90
  homepage_uri: https://github.com/Freshly/spicerack/tree/master/spicerack-styleguide
91
91
  source_code_uri: https://github.com/Freshly/spicerack/tree/master/spicerack-styleguide
92
92
  changelog_uri: https://github.com/Freshly/spicerack/blob/master/spicerack-styleguide/CHANGELOG.md
93
- documentation_uri: https://www.rubydoc.info/gems/spicerack-styleguide/0.24.0
93
+ documentation_uri: https://www.rubydoc.info/gems/spicerack-styleguide/0.25.0
94
94
  post_install_message:
95
95
  rdoc_options: []
96
96
  require_paths: