@@ -6,7 +6,7 @@ inherit_mode:
6
6
7
7
AllCops :
8
8
Exclude :
9
- - app/assets/**/*
9
+ - ' **/ app/assets/**/*'
10
10
- bin/*
11
11
# Exclude db/schema.rb and db/[CONFIGURATION_NAMESPACE]_schema.rb by default.
12
12
# See: https://guides.rubyonrails.org/active_record_multiple_databases.html#setting-up-your-application
@@ -121,8 +121,8 @@ Rails/ActionFilter:
121
121
- action
122
122
- filter
123
123
Include :
124
- - app/controllers/**/*.rb
125
- - app/mailers/**/*.rb
124
+ - ' **/ app/controllers/**/*.rb'
125
+ - ' **/ app/mailers/**/*.rb'
126
126
127
127
Rails/ActionOrder :
128
128
Description : ' Enforce consistent ordering of controller actions.'
@@ -137,7 +137,7 @@ Rails/ActionOrder:
137
137
- update
138
138
- destroy
139
139
Include :
140
- - app/controllers/**/*.rb
140
+ - ' **/ app/controllers/**/*.rb'
141
141
142
142
Rails/ActiveRecordAliases :
143
143
Description : >-
@@ -154,7 +154,7 @@ Rails/ActiveRecordCallbacksOrder:
154
154
Enabled : ' pending'
155
155
VersionAdded : ' 2.7'
156
156
Include :
157
- - app/models/**/*.rb
157
+ - ' **/ app/models/**/*.rb'
158
158
159
159
Rails/ActiveRecordOverride :
160
160
Description : >-
@@ -165,7 +165,7 @@ Rails/ActiveRecordOverride:
165
165
VersionAdded : ' 0.67'
166
166
VersionChanged : ' 2.18'
167
167
Include :
168
- - app/models/**/*.rb
168
+ - ' **/ app/models/**/*.rb'
169
169
170
170
Rails/ActiveSupportAliases :
171
171
Description : >-
@@ -252,7 +252,7 @@ Rails/AttributeDefaultBlockValue:
252
252
Enabled : pending
253
253
VersionAdded : ' 2.9'
254
254
Include :
255
- - ' app/models/**/*'
255
+ - ' **/ app/models/**/*'
256
256
257
257
Rails/BelongsTo :
258
258
Description : >-
@@ -311,8 +311,8 @@ Rails/ContentTag:
311
311
# https://puma.io/puma/Puma/DSL.html#tag-instance_method
312
312
# No helpers are used in normal models and configs.
313
313
Exclude :
314
- - app/models/**/*.rb
315
- - config/**/*.rb
314
+ - ' **/ app/models/**/*.rb'
315
+ - ' **/ config/**/*.rb'
316
316
317
317
Rails/CreateTableWithTimestamps :
318
318
Description : >-
@@ -373,7 +373,7 @@ Rails/Delegate:
373
373
# violation. When set to false, this case is legal.
374
374
EnforceForPrefixed : true
375
375
Exclude :
376
- - app/controllers/**/*.rb
376
+ - ' **/ app/controllers/**/*.rb'
377
377
378
378
Rails/DelegateAllowBlank :
379
379
Description : ' Do not use allow_blank as an option to delegate.'
@@ -444,22 +444,22 @@ Rails/EnumHash:
444
444
Enabled : true
445
445
VersionAdded : ' 2.3'
446
446
Include :
447
- - app/models/**/*.rb
447
+ - ' **/ app/models/**/*.rb'
448
448
449
449
Rails/EnumSyntax :
450
450
Description : ' Use positional arguments over keyword arguments when defining enums.'
451
451
Enabled : pending
452
452
Severity : warning
453
453
VersionAdded : ' 2.26'
454
454
Include :
455
- - app/models/**/*.rb
455
+ - ' **/ app/models/**/*.rb'
456
456
457
457
Rails/EnumUniqueness :
458
458
Description : ' Avoid duplicate integers in hash-syntax `enum` declaration.'
459
459
Enabled : true
460
460
VersionAdded : ' 0.46'
461
461
Include :
462
- - app/models/**/*.rb
462
+ - ' **/ app/models/**/*.rb'
463
463
464
464
Rails/EnvLocal :
465
465
Description : ' Use `Rails.env.local?` instead of `Rails.env.development? || Rails.env.test?`.'
@@ -478,11 +478,11 @@ Rails/EnvironmentVariableAccess:
478
478
VersionAdded : ' 2.10'
479
479
VersionChanged : ' 2.24'
480
480
Include :
481
- - app/**/*.rb
482
- - config/initializers/**/*.rb
483
- - lib/**/*.rb
481
+ - ' **/ app/**/*.rb'
482
+ - ' **/ config/initializers/**/*.rb'
483
+ - ' **/ lib/**/*.rb'
484
484
Exclude :
485
- - lib/**/*.rake
485
+ - ' **/ lib/**/*.rake'
486
486
AllowReads : false
487
487
AllowWrites : false
488
488
@@ -494,11 +494,11 @@ Rails/Exit:
494
494
Enabled : true
495
495
VersionAdded : ' 0.41'
496
496
Include :
497
- - app/**/*.rb
498
- - config/**/*.rb
499
- - lib/**/*.rb
497
+ - ' **/ app/**/*.rb'
498
+ - ' **/ config/**/*.rb'
499
+ - ' **/ lib/**/*.rb'
500
500
Exclude :
501
- - lib/**/*.rake
501
+ - ' **/ lib/**/*.rake'
502
502
503
503
Rails/ExpandedDateRange :
504
504
Description : ' Checks for expanded date range.'
@@ -560,22 +560,22 @@ Rails/HasAndBelongsToMany:
560
560
Enabled : true
561
561
VersionAdded : ' 0.12'
562
562
Include :
563
- - app/models/**/*.rb
563
+ - ' **/ app/models/**/*.rb'
564
564
565
565
Rails/HasManyOrHasOneDependent :
566
566
Description : ' Define the dependent option to the has_many and has_one associations.'
567
567
StyleGuide : ' https://rails.rubystyle.guide#has_many-has_one-dependent-option'
568
568
Enabled : true
569
569
VersionAdded : ' 0.50'
570
570
Include :
571
- - app/models/**/*.rb
571
+ - ' **/ app/models/**/*.rb'
572
572
573
573
Rails/HelperInstanceVariable :
574
574
Description : ' Do not use instance variables in helpers.'
575
575
Enabled : true
576
576
VersionAdded : ' 2.0'
577
577
Include :
578
- - app/helpers/**/*.rb
578
+ - ' **/ app/helpers/**/*.rb'
579
579
580
580
Rails/HttpPositionalArguments :
581
581
Description : ' Use keyword arguments instead of positional arguments in http method calls.'
@@ -606,7 +606,7 @@ Rails/I18nLazyLookup:
606
606
- lazy
607
607
- explicit
608
608
Include :
609
- - ' app/controllers/**/*.rb'
609
+ - ' **/ app/controllers/**/*.rb'
610
610
611
611
Rails/I18nLocaleAssignment :
612
612
Description : ' Prefer the usage of `I18n.with_locale` instead of manually updating `I18n.locale` value.'
@@ -635,8 +635,8 @@ Rails/IgnoredSkipActionFilterOption:
635
635
Enabled : true
636
636
VersionAdded : ' 0.63'
637
637
Include :
638
- - app/controllers/**/*.rb
639
- - app/mailers/**/*.rb
638
+ - ' **/ app/controllers/**/*.rb'
639
+ - ' **/ app/mailers/**/*.rb'
640
640
641
641
Rails/IndexBy :
642
642
Description : ' Prefer `index_by` over `each_with_object`, `to_h`, or `map`.'
@@ -665,7 +665,7 @@ Rails/InverseOf:
665
665
VersionAdded : ' 0.52'
666
666
IgnoreScopes : false
667
667
Include :
668
- - app/models/**/*.rb
668
+ - ' **/ app/models/**/*.rb'
669
669
670
670
Rails/LexicallyScopedActionFilter :
671
671
Description : " Checks that methods specified in the filter's `only` or `except` options are explicitly defined in the class."
@@ -674,8 +674,8 @@ Rails/LexicallyScopedActionFilter:
674
674
Safe : false
675
675
VersionAdded : ' 0.52'
676
676
Include :
677
- - app/controllers/**/*.rb
678
- - app/mailers/**/*.rb
677
+ - ' **/ app/controllers/**/*.rb'
678
+ - ' **/ app/mailers/**/*.rb'
679
679
680
680
Rails/LinkToBlank :
681
681
Description : ' Checks that `link_to` with a `target: "_blank"` have a `rel: "noopener"` option passed to them.'
@@ -693,7 +693,7 @@ Rails/MailerName:
693
693
SafeAutoCorrect : false
694
694
VersionAdded : ' 2.7'
695
695
Include :
696
- - app/mailers/**/*.rb
696
+ - ' **/ app/mailers/**/*.rb'
697
697
698
698
Rails/MatchRoute :
699
699
Description : >-
@@ -703,8 +703,8 @@ Rails/MatchRoute:
703
703
Enabled : ' pending'
704
704
VersionAdded : ' 2.7'
705
705
Include :
706
- - config/routes.rb
707
- - config/routes/**/*.rb
706
+ - ' **/ config/routes.rb'
707
+ - ' **/ config/routes/**/*.rb'
708
708
709
709
Rails/MigrationClassName :
710
710
Description : ' The class name of the migration should match its file name.'
@@ -720,8 +720,8 @@ Rails/MultipleRoutePaths:
720
720
Severity : warning
721
721
VersionAdded : ' 2.29'
722
722
Include :
723
- - config/routes.rb
724
- - config/routes/**/*.rb
723
+ - ' **/ config/routes.rb'
724
+ - ' **/ config/routes/**/*.rb'
725
725
726
726
Rails/NegateInclude :
727
727
Description : ' Prefer `collection.exclude?(obj)` over `!collection.include?(obj)`.'
@@ -757,10 +757,10 @@ Rails/Output:
757
757
VersionAdded : ' 0.15'
758
758
VersionChanged : ' 0.19'
759
759
Include :
760
- - app/**/*.rb
761
- - config/**/*.rb
760
+ - ' **/ app/**/*.rb'
761
+ - ' **/ config/**/*.rb'
762
762
- db/**/*.rb
763
- - lib/**/*.rb
763
+ - ' **/ lib/**/*.rb'
764
764
765
765
Rails/OutputSafety :
766
766
Description : ' The use of `html_safe` or `raw` may be a security risk.'
@@ -832,7 +832,7 @@ Rails/RakeEnvironment:
832
832
- ' **/Rakefile'
833
833
- ' **/*.rake'
834
834
Exclude :
835
- - ' lib/capistrano/tasks/**/*.rake'
835
+ - ' **/ lib/capistrano/tasks/**/*.rake'
836
836
837
837
Rails/ReadWriteAttribute :
838
838
Description : >-
@@ -843,7 +843,7 @@ Rails/ReadWriteAttribute:
843
843
VersionAdded : ' 0.20'
844
844
VersionChanged : ' 0.29'
845
845
Include :
846
- - app/models/**/*.rb
846
+ - ' **/ app/models/**/*.rb'
847
847
848
848
Rails/RedundantActiveRecordAllMethod :
849
849
Description : Detect redundant `all` used as a receiver for Active Record query methods.
@@ -862,7 +862,7 @@ Rails/RedundantAllowNil:
862
862
Enabled : true
863
863
VersionAdded : ' 0.67'
864
864
Include :
865
- - app/models/**/*.rb
865
+ - ' **/ app/models/**/*.rb'
866
866
867
867
Rails/RedundantForeignKey :
868
868
Description : ' Checks for associations where the `:foreign_key` option is redundant.'
@@ -1033,7 +1033,7 @@ Rails/ScopeArgs:
1033
1033
VersionAdded : ' 0.19'
1034
1034
VersionChanged : ' 2.12'
1035
1035
Include :
1036
- - app/models/**/*.rb
1036
+ - ' **/ app/models/**/*.rb'
1037
1037
1038
1038
Rails/SelectMap :
1039
1039
Description : ' Checks for uses of `select(:column_name)` with `map(&:column_name)`.'
@@ -1102,7 +1102,7 @@ Rails/StrongParametersExpect:
1102
1102
Reference : ' https://api.rubyonrails.org/classes/ActionController/Parameters.html#method-i-expect'
1103
1103
Enabled : pending
1104
1104
Include :
1105
- - app/controllers/**/*.rb
1105
+ - ' **/ app/controllers/**/*.rb'
1106
1106
SafeAutoCorrect : false
1107
1107
VersionAdded : ' 2.29'
1108
1108
@@ -1113,7 +1113,7 @@ Rails/TableNameAssignment:
1113
1113
Enabled : false
1114
1114
VersionAdded : ' 2.14'
1115
1115
Include :
1116
- - app/models/**/*.rb
1116
+ - ' **/ app/models/**/*.rb'
1117
1117
1118
1118
Rails/ThreeStateBooleanColumn :
1119
1119
Description : ' Add a default value and a `NOT NULL` constraint to boolean columns.'
@@ -1197,7 +1197,7 @@ Rails/UniqueValidationWithoutIndex:
1197
1197
Enabled : true
1198
1198
VersionAdded : ' 2.5'
1199
1199
Include :
1200
- - app/models/**/*.rb
1200
+ - ' **/ app/models/**/*.rb'
1201
1201
1202
1202
Rails/UnknownEnv :
1203
1203
Description : ' Use correct environment name.'
@@ -1216,7 +1216,7 @@ Rails/UnusedIgnoredColumns:
1216
1216
VersionAdded : ' 2.11'
1217
1217
VersionChanged : ' 2.25'
1218
1218
Include :
1219
- - app/models/**/*.rb
1219
+ - ' **/ app/models/**/*.rb'
1220
1220
1221
1221
Rails/UnusedRenderContent :
1222
1222
Description : ' Do not specify body content for a response with a non-content status code.'
@@ -1230,7 +1230,7 @@ Rails/Validation:
1230
1230
VersionAdded : ' 0.9'
1231
1231
VersionChanged : ' 0.41'
1232
1232
Include :
1233
- - app/models/**/*.rb
1233
+ - ' **/ app/models/**/*.rb'
1234
1234
1235
1235
Rails/WhereEquals :
1236
1236
Description : ' Pass conditions to `where` and `where.not` as a hash instead of manually constructing SQL.'
0 commit comments