1
1
<%
2
+ require "rubocop/shopify/gem_version_string_comparable_backport"
3
+
2
4
rubocop_version = Gem.loaded_specs.fetch("rubocop").version
3
- v1_57 = Gem::Version.new("1.57")
4
- v1_58 = Gem::Version.new("1.58")
5
- v1_59 = Gem::Version.new("1.59")
6
5
% >
7
6
8
7
inherit_mode :
@@ -190,21 +189,23 @@ Lint/IncompatibleIoSelectWithFiberScheduler:
190
189
Lint/InterpolationCheck :
191
190
Enabled : false
192
191
193
- <% if rubocop_version >= v1_59 % >
192
+ <% if rubocop_version >= "1.59" % >
194
193
Lint/ItWithoutArgumentsInBlock :
195
194
Enabled : true
196
195
<% end % >
197
196
198
197
Lint/LambdaWithoutLiteralBlock :
199
198
Enabled : false
200
199
201
- <% if rubocop_version >= v1_58 % >
200
+ <% if rubocop_version >= "1.58" % >
202
201
Lint/LiteralAssignmentInCondition :
203
202
Enabled : true
204
203
<% end % >
205
204
205
+ <% if rubocop_version >= "1.53" % >
206
206
Lint/MixedCaseRange :
207
207
Enabled : true
208
+ <% end % >
208
209
209
210
Lint/MixedRegexpCaptureTypes :
210
211
Enabled : false
@@ -239,8 +240,10 @@ Lint/RaiseException:
239
240
Lint/RedundantDirGlobSort :
240
241
Enabled : false
241
242
243
+ <% if rubocop_version >= "1.53" % >
242
244
Lint/RedundantRegexpQuantifiers :
243
245
Enabled : true
246
+ <% end % >
244
247
245
248
Lint/RedundantRequireStatement :
246
249
Enabled : false
@@ -727,8 +730,10 @@ Style/RandomWithOffset:
727
730
Style/RedundantArgument :
728
731
Enabled : false
729
732
733
+ <% if rubocop_version >= "1.52" % >
730
734
Style/RedundantArrayConstructor :
731
735
Enabled : true
736
+ <% end % >
732
737
733
738
Style/RedundantAssignment :
734
739
Enabled : false
@@ -742,8 +747,10 @@ Style/RedundantConditional:
742
747
Style/RedundantConstantBase :
743
748
Enabled : true
744
749
750
+ <% if rubocop_version >= "1.53" % >
745
751
Style/RedundantCurrentDirectoryInPath :
746
752
Enabled : true
753
+ <% end % >
747
754
748
755
Style/RedundantDoubleSplatHashBraces :
749
756
Enabled : true
@@ -757,8 +764,10 @@ Style/RedundantFetchBlock:
757
764
Style/RedundantFileExtensionInRequire :
758
765
Enabled : false
759
766
767
+ <% if rubocop_version >= "1.52" % >
760
768
Style/RedundantFilterChain :
761
769
Enabled : true
770
+ <% end % >
762
771
763
772
Style/RedundantHeredocDelimiterQuotes :
764
773
Enabled : true
@@ -769,14 +778,18 @@ Style/RedundantInitialize:
769
778
Style/RedundantLineContinuation :
770
779
Enabled : true
771
780
781
+ <% if rubocop_version >= "1.53" % >
772
782
Style/RedundantRegexpArgument :
773
783
Enabled : true
784
+ <% end % >
774
785
775
786
Style/RedundantRegexpCharacterClass :
776
787
Enabled : false
777
788
789
+ <% if rubocop_version >= "1.52" % >
778
790
Style/RedundantRegexpConstructor :
779
791
Enabled : true
792
+ <% end % >
780
793
781
794
Style/RedundantRegexpEscape :
782
795
Enabled : false
@@ -802,16 +815,18 @@ Style/RescueStandardError:
802
815
Style/ReturnNil :
803
816
Enabled : true
804
817
818
+ <% if rubocop_version >= "1.53" % >
805
819
Style/ReturnNilInPredicateMethodDefinition :
806
820
Enabled : true
821
+ <% end % >
807
822
808
823
Style/SelectByRegexp :
809
824
Enabled : false
810
825
811
826
Style/SingleArgumentDig :
812
827
Enabled : false
813
828
814
- <% if rubocop_version >= v1_57 % >
829
+ <% if rubocop_version >= "1.57" % >
815
830
Style/SingleLineDoEndBlock :
816
831
Enabled : true
817
832
<% end % >
@@ -840,7 +855,7 @@ Style/StringLiteralsInInterpolation:
840
855
Style/StructInheritance :
841
856
Enabled : false
842
857
843
- <% if rubocop_version >= v1_58 % >
858
+ <% if rubocop_version >= "1.58" % >
844
859
Style/SuperWithArgsParentheses :
845
860
Enabled : true
846
861
<% end % >
@@ -875,8 +890,10 @@ Style/UnpackFirst:
875
890
Style/WordArray :
876
891
EnforcedStyle : brackets
877
892
893
+ <% if rubocop_version >= "1.53" % >
878
894
Style/YAMLFileRead :
879
895
Enabled : true
896
+ <% end % >
880
897
881
898
Style/YodaCondition :
882
899
Enabled : false
0 commit comments