-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.swiftlint.yml
84 lines (65 loc) · 1.46 KB
/
.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
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
# List of rules with definitions
# https://github.com/realm/SwiftLint/blob/master/Rules.md
# Find all the available rules by running:
# 1. With terminal navigate to project folder
# 2. Write: swiftlint rules
# rule identifiers to exclude from running
disabled_rules:
- todo
- operator_whitespace
- trailing_whitespace
opt_in_rules:
- attributes
- closure_spacing
- empty_count
- explicit_init
- force_unwrapping
- nimble_operator
- operator_usage_whitespace
- overridden_super_call
- prohibited_super_call
- redundant_nil_coalescing
- switch_case_on_newline
- closure_end_indentation
- multiline_parameters
- vertical_parameter_alignment_on_call
- object_literal
# rules with additional configuration
line_length:
warning: 140
error: 150
function_parameter_count:
warning: 6
error: 8
function_body_length:
warning: 50
error: 70
type_name:
min_length: 2
max_length: 60
identifier_name:
min_length: 2
max_length: 60
file_length:
warning: 750
error: 1000
type_body_length:
warning: 500
error: 550
cyclomatic_complexity:
ignores_case_statements: true
private_outlet:
allow_private_set: true
trailing_whitespace:
ignores_empty_lines: true
ignores_comments: true
object_literal:
color_literal: false
conditional_returns_on_newline:
if_only: true
excluded:
- Pods
- DerivedData
# Temporary disable until current style warnings are fixed.
#warning_threshold: 15
reporter: "xcode" # reporter type (xcode, json, csv, checkstyle, junit, html, emoji)