-
-
Notifications
You must be signed in to change notification settings - Fork 33
/
Copy path.swiftlint.yml
34 lines (29 loc) · 1005 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
excluded:
- "**/.build"
- "Sources/Core/Sources/Cache/Protobuf/Generated/BlockRegistry.pb.swift"
- "Sources/Core/Sources/Cache/Protobuf/Generated/BlockModelPalette.pb.swift"
# TODO: Reexclude once swiftlint github action is updated to support globs
# - "**/*.pb.swift"
disabled_rules:
- switch_case_alignment
- trailing_whitespace
- identifier_name
- opening_brace # Has false positives in the code base
# TODO: Re-enable these rules later once more warnings are fixed
- nesting
- todo
line_length: 160
type_body_length: 300
function_parameter_count: 8
file_length: 500
function_body_length: 50
cyclomatic_complexity:
error: 40 # TODO: reset once more occurrences are fixed
# Custom rules
custom_rules:
comments_space: # from https://github.com/brandenr/swiftlintconfig
name: "Space After Comment"
regex: '(^ *//\w+)'
message: "There should be a space after //"
severity: error
# TODO: Once there are less warnings and violations, make the rules stricter and add some opt in ones