]> git.openstreetmap.org Git - rails.git/blob - .rubocop.yml
77f26d863bf5b41a23ea4ca47540ab36eb21ff7c
[rails.git] / .rubocop.yml
1 inherit_from: .rubocop_todo.yml
2
3 require:
4   - rubocop-performance
5   - rubocop-rails
6
7 AllCops:
8   TargetRubyVersion: 2.5
9   Exclude:
10     - 'vendor/**/*'
11
12 Rails:
13   Enabled: true
14
15 Layout/ExtraSpacing:
16   AllowForAlignment: true
17
18 Lint/PercentStringArray:
19   Exclude:
20     - 'config/initializers/secure_headers.rb'
21     - 'app/controllers/application_controller.rb'
22     - 'app/controllers/site_controller.rb'
23
24 Metrics/BlockLength:
25   Exclude:
26     - 'config/routes.rb'
27
28 Metrics/ClassLength:
29   Exclude:
30     - 'test/**/*'
31
32 Metrics/ModuleLength:
33   Max: 150
34
35 Naming/FileName:
36   Exclude:
37     - 'script/deliver-message'
38     - 'script/locale/reload-languages'
39     - 'script/update-spam-blocks'
40
41 Naming/MethodParameterName:
42   Enabled: false
43
44 Rails/CreateTableWithTimestamps:
45   Enabled: false
46
47 Rails/FindEach:
48   Enabled: false
49
50 Rails/HasManyOrHasOneDependent:
51   Enabled: false
52
53 Rails/HttpPositionalArguments:
54   Enabled: false
55
56 Rails/InverseOf:
57   Enabled: false
58
59 Rails/SkipsModelValidations:
60   Exclude:
61     - 'db/migrate/*.rb'
62     - 'app/controllers/users_controller.rb'
63
64 Style/BracesAroundHashParameters:
65   EnforcedStyle: context_dependent
66
67 Style/Documentation:
68   Enabled: false
69
70 Style/FormatStringToken:
71   EnforcedStyle: template
72
73 Style/IfInsideElse:
74   Enabled: false
75
76 Style/GuardClause:
77   Enabled: false
78
79 Style/HashSyntax:
80   EnforcedStyle: hash_rockets
81   Exclude:
82     - 'lib/tasks/testing.rake'
83     - 'config/initializers/wrap_parameters.rb'
84
85 Style/MixinUsage:
86   Exclude:
87     - 'bin/setup'
88     - 'bin/update'
89
90 Style/StringLiterals:
91   EnforcedStyle: double_quotes
92
93 Style/SymbolArray:
94   EnforcedStyle: brackets