]> git.openstreetmap.org Git - rails.git/blob - .rubocop.yml
Add section on using rbenv, separate from main installation instructions.
[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 Naming/FileName:
33   Exclude:
34     - 'script/deliver-message'
35     - 'script/locale/reload-languages'
36     - 'script/update-spam-blocks'
37
38 Naming/UncommunicativeMethodParamName:
39   Enabled: false
40
41 Rails/ApplicationRecord:
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/FormatStringToken:
68   EnforcedStyle: template
69
70 Style/IfInsideElse:
71   Enabled: false
72
73 Style/GuardClause:
74   Enabled: false
75
76 Style/HashSyntax:
77   EnforcedStyle: hash_rockets
78   Exclude:
79     - 'lib/tasks/testing.rake'
80     - 'config/initializers/wrap_parameters.rb'
81
82 Style/MixinUsage:
83   Exclude:
84     - 'bin/setup'
85     - 'bin/update'
86
87 Style/StringLiterals:
88   EnforcedStyle: double_quotes
89
90 Style/SymbolArray:
91   EnforcedStyle: brackets