]> git.openstreetmap.org Git - rails.git/blob - .rubocop.yml
Use an inline list for the login auth buttons
[rails.git] / .rubocop.yml
1 inherit_from: .rubocop_todo.yml
2
3 require:
4   - rubocop-capybara
5   - rubocop-factory_bot
6   - rubocop-minitest
7   - rubocop-performance
8   - rubocop-rails
9   - rubocop-rake
10
11 AllCops:
12   TargetRubyVersion: 3.0
13   NewCops: enable
14   Exclude:
15     - 'vendor/**/*'
16
17 Rails:
18   Enabled: true
19
20 # Config can be removed after https://github.com/rubocop/rubocop-factory_bot/issues/53
21 FactoryBot/AssociationStyle:
22   Include:
23     - 'test/factories/**/*'
24
25 Layout/ExtraSpacing:
26   AllowForAlignment: true
27
28 Lint/PercentStringArray:
29   Exclude:
30     - 'config/initializers/secure_headers.rb'
31     - 'app/controllers/application_controller.rb'
32     - 'app/controllers/site_controller.rb'
33
34 Metrics/BlockLength:
35   Exclude:
36     - 'config/routes.rb'
37
38 Metrics/ClassLength:
39   Exclude:
40     - 'test/**/*'
41
42 Metrics/ModuleLength:
43   Max: 150
44
45 Naming/FileName:
46   Exclude:
47     - 'script/deliver-message'
48     - 'script/update-spam-blocks'
49
50 Naming/MethodParameterName:
51   Enabled: false
52
53 Rails/CreateTableWithTimestamps:
54   Enabled: false
55
56 Rails/FindEach:
57   Enabled: false
58
59 Rails/HasManyOrHasOneDependent:
60   Enabled: false
61
62 Rails/HttpPositionalArguments:
63   Enabled: false
64
65 Rails/ReflectionClassName:
66   Enabled: false
67
68 Rails/SkipsModelValidations:
69   Exclude:
70     - 'db/migrate/*.rb'
71     - 'app/controllers/users_controller.rb'
72
73 Style/Documentation:
74   Enabled: false
75
76 Style/FormatStringToken:
77   Exclude:
78     - 'config/routes.rb'
79
80 Style/IfInsideElse:
81   Enabled: false
82
83 Style/GuardClause:
84   Enabled: false
85
86 Style/HashEachMethods:
87   Enabled: true
88
89 Style/HashSyntax:
90   EnforcedStyle: hash_rockets
91   Exclude:
92     - 'lib/tasks/testing.rake'
93     - 'config/initializers/wrap_parameters.rb'
94
95 Style/HashTransformKeys:
96   Enabled: true
97
98 Style/HashTransformValues:
99   Enabled: true
100
101 Style/MixinUsage:
102   Exclude:
103     - 'bin/setup'
104     - 'bin/update'
105
106 Style/StringLiterals:
107   EnforcedStyle: double_quotes
108
109 Style/SymbolArray:
110   EnforcedStyle: brackets