Skip to content

Commit a1bfba2

Browse files
committed
Update config exclusion
Remove Rails -specific configurations.
1 parent d8fe4c3 commit a1bfba2

2 files changed

Lines changed: 171 additions & 42 deletions

File tree

.rubocop.yml

Lines changed: 14 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
1+
inherit_from:
2+
- .rubocop_todo.yml
3+
4+
inherit_mode:
5+
merge:
6+
- Exclude
7+
18
plugins:
29
- rubocop-performance
310
- rubocop-rspec
411
- rubocop-rake
512

13+
AllCops:
14+
NewCops: enable
15+
TargetRubyVersion: 3.2
16+
Exclude:
17+
- 'bin/**/*'
18+
- 'tmp/**/*'
19+
620
Bundler/OrderedGems:
721
Enabled: false
822

@@ -54,28 +68,12 @@ Style/TrailingCommaInHashLiteral:
5468
Style/FormatStringToken:
5569
Enabled: false
5670

57-
Metrics/BlockLength:
58-
Max: 30
59-
Exclude:
60-
- 'spec/**/*.rb'
61-
- 'config/environments/**/*.rb'
62-
- 'config/routes.rb'
63-
- "config/initializers/simple_form_bootstrap.rb"
64-
- 'db/**/*'
65-
66-
Metrics/AbcSize:
67-
Max: 20
68-
Exclude:
69-
- 'db/**/*'
70-
7171
Metrics/MethodLength:
7272
Max: 20
7373
CountAsOne:
7474
- array
7575
- hash
7676
- heredoc
77-
Exclude:
78-
- 'db/migrate/*'
7977

8078
Metrics/ModuleLength:
8179
CountAsOne:
@@ -88,28 +86,13 @@ Metrics/ClassLength:
8886
- array
8987
- hash
9088
- heredoc
91-
Exclude:
92-
- 'db/**/*'
93-
94-
Metrics/ParameterLists:
95-
Max: 7
96-
MaxOptionalParameters: 5
97-
Exclude:
98-
- "spec/components/**/*.rb"
99-
- "app/components/**/*.rb"
10089

10190
Naming/InclusiveLanguage:
10291
Enabled: false
10392

10493
RSpec/MultipleExpectations:
10594
Enabled: false
10695

107-
RSpec/DescribeClass:
108-
Exclude:
109-
- 'spec/routing/**/*'
110-
- 'spec/system/**/*'
111-
- 'spec/views/**/*'
112-
11396
RSpec/DescribedClass:
11497
SkipBlocks: true
11598

@@ -119,10 +102,6 @@ RSpec/EmptyExampleGroup:
119102
RSpec/ExampleLength:
120103
Enabled: false
121104

122-
RSpec/InstanceVariable:
123-
Exclude:
124-
- 'spec/views/**/*'
125-
126105
RSpec/NestedGroups:
127106
Max: 6
128107

@@ -143,10 +122,3 @@ RSpec/AnyInstance:
143122

144123
RSpec/VerifiedDoubles:
145124
Enabled: false
146-
147-
AllCops:
148-
NewCops: enable
149-
TargetRubyVersion: 3.2
150-
Exclude:
151-
- 'bin/**/*'
152-
- 'tmp/**/*'

.rubocop_todo.yml

Lines changed: 157 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,157 @@
1+
# This configuration was generated by
2+
# `rubocop --auto-gen-config`
3+
# on 2025-12-15 16:17:55 UTC using RuboCop version 1.81.7.
4+
# The point is for the user to remove these configuration records
5+
# one by one as the offenses are removed from the code base.
6+
# Note that changes in the inspected code, or installation of new
7+
# versions of RuboCop, may require this file to be generated again.
8+
9+
# Offense count: 8
10+
# This cop supports safe autocorrection (--autocorrect).
11+
# Configuration parameters: Max, AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, IgnoreCopDirectives, AllowedPatterns, SplitStrings.
12+
# URISchemes: http, https
13+
Layout/LineLength:
14+
Exclude:
15+
- 'lib/phony/countries/brazil.rb'
16+
- 'lib/phony/countries/cambodia.rb'
17+
- 'lib/phony/countries/ireland.rb'
18+
- 'lib/phony/countries/italy.rb'
19+
- 'lib/phony/countries/somalia.rb'
20+
- 'lib/phony/countries/united_kingdom.rb'
21+
- 'phony.gemspec'
22+
23+
# Offense count: 1
24+
# Configuration parameters: AllowedParentClasses.
25+
Lint/MissingSuper:
26+
Exclude:
27+
- 'lib/phony/national_splitters/fixed.rb'
28+
29+
# Offense count: 5
30+
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
31+
Metrics/AbcSize:
32+
Max: 27
33+
34+
# Offense count: 9
35+
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
36+
# AllowedMethods: refine
37+
Metrics/BlockLength:
38+
Max: 758
39+
40+
# Offense count: 1
41+
# Configuration parameters: CountComments, CountAsOne.
42+
Metrics/ClassLength:
43+
Max: 126
44+
45+
# Offense count: 9
46+
# Configuration parameters: LengthThreshold.
47+
Metrics/CollectionLiteralLength:
48+
Exclude:
49+
- 'lib/phony/countries/argentina.rb'
50+
- 'lib/phony/countries/germany.rb'
51+
- 'lib/phony/countries/india.rb'
52+
- 'lib/phony/countries/japan.rb'
53+
- 'lib/phony/countries/russia_kazakhstan_abkhasia_south_ossetia.rb'
54+
- 'lib/phony/countries/ukraine.rb'
55+
- 'lib/phony/countries/united_kingdom.rb'
56+
- 'spec/functional/plausibility_spec.rb'
57+
58+
# Offense count: 6
59+
# Configuration parameters: AllowedMethods, AllowedPatterns.
60+
Metrics/CyclomaticComplexity:
61+
Max: 13
62+
63+
# Offense count: 2
64+
# Configuration parameters: CountComments, Max, CountAsOne, AllowedMethods, AllowedPatterns.
65+
Metrics/MethodLength:
66+
Exclude:
67+
- 'lib/phony/country.rb'
68+
- 'spec/functional/plausibility_spec.rb'
69+
70+
# Offense count: 1
71+
# Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
72+
Metrics/ParameterLists:
73+
Max: 7
74+
75+
# Offense count: 5
76+
# Configuration parameters: AllowedMethods, AllowedPatterns.
77+
Metrics/PerceivedComplexity:
78+
Max: 13
79+
80+
# Offense count: 2
81+
# Configuration parameters: NamePrefix, ForbiddenPrefixes, AllowedMethods, MethodDefinitionMacros, UseSorbetSigs.
82+
# NamePrefix: is_, has_, have_, does_
83+
# ForbiddenPrefixes: is_, has_, have_, does_
84+
# AllowedMethods: is_a?
85+
# MethodDefinitionMacros: define_method, define_singleton_method
86+
Naming/PredicatePrefix:
87+
Exclude:
88+
- 'lib/phony/config.rb'
89+
90+
# Offense count: 8
91+
# Configuration parameters: EnforcedStyle, CheckMethodNames, CheckSymbols, AllowedIdentifiers, AllowedPatterns.
92+
# SupportedStyles: snake_case, normalcase, non_integer
93+
# AllowedIdentifiers: TLS1_1, TLS1_2, capture3, iso8601, rfc1123_date, rfc822, rfc2822, rfc3339, x86_64
94+
Naming/VariableNumber:
95+
Exclude:
96+
- 'Gemfile'
97+
- 'lib/phony/countries/brazil.rb'
98+
- 'lib/phony/countries/sweden.rb'
99+
100+
# Offense count: 1
101+
RSpec/BeforeAfterAll:
102+
Exclude:
103+
- 'spec/functional/config_spec.rb'
104+
105+
# Offense count: 2
106+
# Configuration parameters: IgnoredMetadata.
107+
RSpec/DescribeClass:
108+
Exclude:
109+
- 'spec/functional/plausibility_spec.rb'
110+
- 'spec/lib/phony/countries_spec.rb'
111+
112+
# Offense count: 1
113+
RSpec/IdenticalEqualityAssertion:
114+
Exclude:
115+
- 'spec/lib/phony/national_splitters/fixed_spec.rb'
116+
117+
# Offense count: 1
118+
RSpec/MultipleDescribes:
119+
Exclude:
120+
- 'spec/lib/phony_spec.rb'
121+
122+
# Offense count: 1
123+
RSpec/PendingWithoutReason:
124+
Exclude:
125+
- 'spec/lib/phony/country_spec.rb'
126+
127+
# Offense count: 1
128+
RSpec/RemoveConst:
129+
Exclude:
130+
- 'spec/functional/config_spec.rb'
131+
132+
# Offense count: 4
133+
RSpec/RepeatedExample:
134+
Exclude:
135+
- 'spec/lib/phony/country_codes_spec.rb'
136+
137+
# Offense count: 4
138+
RSpec/RepeatedExampleGroupDescription:
139+
Exclude:
140+
- 'spec/lib/phony/countries_spec.rb'
141+
- 'spec/lib/phony/national_splitters/fixed_spec.rb'
142+
143+
# Offense count: 4
144+
# This cop supports safe autocorrection (--autocorrect).
145+
# Configuration parameters: AllowOnConstant, AllowOnSelfClass.
146+
Style/CaseEquality:
147+
Exclude:
148+
- 'lib/phony/country.rb'
149+
- 'lib/phony/country_codes.rb'
150+
- 'lib/phony/local_splitters/fixed.rb'
151+
152+
# Offense count: 11
153+
Style/ClassVars:
154+
Exclude:
155+
- 'lib/phony/country.rb'
156+
- 'lib/phony/country_codes.rb'
157+
- 'lib/phony/vanity.rb'

0 commit comments

Comments
 (0)