Merge pull request #17 from TouchInstinct/fix/opt-in-rules

Fix. Missed rules
This commit is contained in:
Igor Kislyuk 2017-08-24 14:49:52 +03:00 committed by GitHub
commit 8e3c6f9925
1 changed files with 21 additions and 25 deletions

View File

@ -2,6 +2,27 @@ disabled_rules:
- identifier_name
opt_in_rules:
- private_outlet
- closure_spacing
- closure_end_indentation
- empty_count
- explicit_init
- extension_access_modifier
- fatal_error_message
- file_header
- first_where
- force_unwrapping
- implicit_return
- let_var_whitespace
- multiline_parameters
- nimble_operator - discuss
- conditional_returns_on_newline
- number_separator
- object_literal
- overridden_super_call
- prohibited_super_call
- redundant_nil_coalescing
- unneeded_parentheses_in_closure_argument
- vertical_parameter_alignment_on_call
excluded:
- Carthage
- Pods
@ -79,31 +100,6 @@ custom_rules:
message: "Please use `weak` instead. "
severity: error
empty_count_zero:
name: "Empty Count Violation"
regex: '\.count\s*(==|!=|<|<=|>|>=)\s*0'
message: "Prefer checking `isEmpty` over comparing `count` to zero."
severity: warning
# Should be { braces_body } instead of {braces_body}
spaces_around_braces:
included: ".*.swift"
name: "Spaces around the braces"
regex: '(([A-Za-z0-9])[\{\}])|([\{\}]([A-Za-z0-9]))'
message: "No spaces around the braces"
severity: error
match_kinds:
- attribute.builtin
- attribute.id
- buildconfig.id
- buildconfig.keyword
- identifier
- keyword
- objectliteral
- parameter
- placeholder
- typeidentifier
inout_keyword:
name: "Inout"
regex: 'inout'