-
Notifications
You must be signed in to change notification settings - Fork 12
/
.swiftlint.yml
40 lines (39 loc) · 1002 Bytes
/
.swiftlint.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
disabled_rules: # rule identifiers to exclude from running
- class_delegate_protocol
- colon
- cyclomatic_complexity
- file_length
- force_try
- function_body_length
- function_parameter_count
- generic_type_name
- identifier_name
- large_tuple
- leading_whitespace
- line_length
- nesting
- opening_brace
- statement_position
- todo
- trailing_whitespace
- type_body_length
- void_return
- weak_delegate
- xctfail_message
opt_in_rules: # some rules are only opt-in
included: # paths to include during linting. `--path` is ignored if present.
- AutoGraph
- QueryBuilder
excluded: # paths to ignore during linting. Takes precedence over `included`.
- Pods
custom_rules:
else_newline:
name: Newline before else
regex: (\}\h*else\s*\{)
message: Else statements should go on a new line
severity: warning
weak_delegate:
name: Weak delegate
regex: (?<=\n)\h*(var delegate)
message: Delegates should be weak
severity: error