-
Notifications
You must be signed in to change notification settings - Fork 3
/
.rubocop.yml
104 lines (88 loc) · 2.13 KB
/
.rubocop.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
---
require:
- standard
- standard-custom
- standard-performance
- standard-rails
- rubocop-performance
- rubocop-rails
- ./lib/bops/cop.rb
inherit_gem:
standard: config/base.yml
standard-custom: config/base.yml
standard-performance: config/base.yml
standard-rails: config/base.yml
AllCops:
TargetRubyVersion: 3.3.0
NewCops: enable
SuggestExtensions: false
Exclude:
- 'bin/*'
- 'bops-applicants/**/*'
- 'db/schema.rb'
- 'config/environments/**'
- 'config/puma.rb'
- 'storage/**/*'
- 'tmp/**/*'
- 'vendor/**/*'
- 'engines/*/bin/*'
Layout/EmptyLineBetweenDefs:
AllowAdjacentOneLineDefs: true
Style/FrozenStringLiteralComment:
Enabled: true
EnforcedStyle: always_true
Style/HaveCurrentPathLiteral:
Enabled: true
Exclude:
- 'app/**/*'
- 'config/**/*'
- 'db/**/*'
- 'lib/**/*'
IgnoreHelpers: []
Style/VisitLiteral:
Enabled: true
Exclude:
- 'app/**/*'
- 'config/**/*'
- 'db/**/*'
- 'lib/**/*'
IgnoreHelpers:
- current_path
Style/NoFetchWithLiteralNilDefault:
Enabled: true
Style/UseGovukLinkHelper:
Enable: true
# past migrations are ignored; we don't expect to go back and edit them ever,
# we'll fix them in future migrations if at all.
Rails/BulkChangeTable:
Exclude:
- db/migrate/202[0123]*
Rails/ReversibleMigration:
Exclude:
- db/migrate/202[0123]*
Rails/ReversibleMigrationMethodDefinition:
Exclude:
- db/migrate/202[0123]*
Rails/ThreeStateBooleanColumn:
Exclude:
- db/migrate/202[012]*
- db/migrate/20230*
- db/migrate/202310*
Rails/ApplicationJob:
Exclude:
# specs ignored so we can test concerns in isolation
- engines/*/spec/**/*
# False positive: if being used in migrations, behaviour is different and intentional
Rails/ApplicationRecord:
Exclude:
- db/migrate/*
# Ignore scopes as Rails 7.0+ will find the inverse of automatically
Rails/InverseOf:
IgnoreScopes: true
Rails/SaveBang:
Exclude:
# past migrations ignored, see above
- db/migrate/202[0123]*
# specs ignored because we might rely on this behaviour for testing errors
- engines/*/spec/**/*
- spec/**/*