Revision control

1
disabled_rules: # rule identifiers to exclude from running
2
- variable_name
3
- todo
4
- trailing_newline
5
- type_name
6
- function_body_length
7
- missing_docs
8
- valid_docs
9
- cyclomatic_complexity
10
- type_body_length
11
- function_parameter_count
12
- file_length
13
- mark
14
- unused_closure_parameter
15
- empty_parentheses_with_trailing_closure
16
- redundant_string_enum_value
17
- large_tuple
18
- class_delegate_protocol
19
- syntactic_sugar
20
- implicit_getter
21
- weak_delegate
22
- shorthand_operator
23
- trailing_comma
24
- unused_optional_binding
25
- private_over_fileprivate
26
- empty_enum_arguments
27
- discarded_notification_center_observer
28
- block_based_kvo
29
- nesting
30
- is_disjoint
31
- multiple_closures_with_trailing_closure
32
- fallthrough
33
- switch_case_alignment
34
- trailing_whitespace
35
- leading_whitespace
36
- operator_whitespace
37
- legacy_cggeometry_functions
38
- unneeded_break_in_switch
39
- closure_parameter_position
40
opt_in_rules: # some rules are only opt-in
41
- closing_brace
42
- opening_brace
43
- return_arrow_whitespace
44
- trailing_semicolon
45
- statement_position
46
- explicit_init
47
- shorthand_operator
48
- file_header
49
- deployment_target
50
- discouraged_optional_collection
51
- duplicate_imports
52
- empty_string
53
- overridden_super_call
54
- prohibited_interface_builder
55
- prohibited_super_call
56
- protocol_property_accessors_order
57
- redundant_objc_attribute
58
- redundant_type_annotation
59
- unused_import
60
# Find all the available rules by running:
61
# swiftlint rules
62
included: # paths to include during linting. `--path` is ignored if present.
63
excluded: # paths to ignore during linting. Takes precedence over `included`.
64
- Carthage
65
- Pods
66
- Source/ExcludedFolder
67
- Source/ExcludedFile.swift
68
- ThirdParty
69
- FxA
70
- FxAClient
71
- build
72
- UITests/EarlGrey.swift
73
- Storage/ThirdParty/SwiftData.swift
74
- UITests/
75
- XCUITests/
76
- SyncTests/
77
- StorageTests/
78
- ReadingListTests/
79
- ClientTests/
80
- AccountTests/
81
- fastlane/
82
- SharedTests/
83
- Client/Assets/Search/get_supported_locales.swift
84
85
# configurable rules can be customized from this configuration file
86
# binary rules can set their severity level
87
trailing_semicolon: error
88
empty_count: error
89
closing_brace: error
90
opening_brace: error
91
return_arrow_whitespace: error
92
statement_position: error
93
colon: error
94
comma: error
95
force_try: warning
96
force_cast: warning
97
98
99
file_header:
100
required_string: "/* This Source Code Form is subject to the terms of the Mozilla Public\n * License, v. 2.0. If a copy of the MPL was not distributed with this\n * file, You can obtain one at http://mozilla.org/MPL/2.0/. */"
101
line_length: 1000
102
103
reporter: "json" # reporter type (xcode, json, csv, checkstyle)