Skip to content

Commit

Permalink
Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
ekazaev committed Jan 5, 2021
1 parent 42ab870 commit 22bb1b6
Show file tree
Hide file tree
Showing 5 changed files with 77 additions and 79 deletions.
1 change: 0 additions & 1 deletion .swiftlint.yml

This file was deleted.

73 changes: 73 additions & 0 deletions .swiftlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
disabled_rules: # rule identifiers to exclude from running
- colon
- comma
- control_statement
- nesting
opt_in_rules: # some rules are only opt-in
- empty_count
# Find all the available rules by running:
# swiftlint rules
included: # paths to include during linting. `--path` is ignored if present.
- Example
- RouteComposer
excluded: # paths to ignore during linting. Takes precedence over `included`.
- Carthage
- Pods
- Source/ExcludedFolder
- Source/ExcludedFile.swift
- Source/*/ExcludedFile.swift # Exclude files with a wildcard

# configurable rules can be customized from this configuration file
# binary rules can set their severity level
force_cast: warning # implicitly
force_try:
severity: warning # explicitly
# rules that have both warning and error levels, can set just the warning level
# implicitly
line_length: 180

# they can set both implicitly with an array
type_body_length:
- 400 # warning
- 500 # error

function_body_length:
- 150 # warning
- 200 # error

cyclomatic_complexity:
- 15 # warning
- 25 # error


# or they can set both explicitly
file_length:
warning: 500
error: 1200

# naming rules can set warnings/errors for min_length and max_length
# additionally they can set excluded names
type_name:
min_length: 4 # only warning
max_length: # warning and error
warning: 40
error: 50
excluded: iPhone # excluded via string

identifier_name:
min_length: # only min_length
error: 3 # only error
excluded: # excluded via string array
- id
- vc
- key
- url
- URL
- GlobalAPIKey

function_parameter_count: 6

large_tuple:
- 4
- 10
reporter: "xcode" # reporter type (xcode, json, csv, checkstyle, junit, html, emoji, sonarqube)
2 changes: 1 addition & 1 deletion ChatLayout.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'ChatLayout'
s.version = '1.0.0'
s.version = '0.6.3'
s.summary = 'Chat UI Library. An alternative solution to MessageKit. It uses custom UICollectionViewLayout to provide you full control over the presentation.'
s.swift_version = '5.2'

Expand Down
5 changes: 1 addition & 4 deletions ChatLayout/Classes/Core/Model/StateController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -267,10 +267,7 @@ final class StateController {

func section(at index: Int, at state: ModelState) -> SectionModel {
guard index < layout(at: state).sections.count else {
preconditionFailure("""
Section index \(index) is bigger than the amount of
sections \(layout(at: state).sections.count)
""")
preconditionFailure("Section index \(index) is bigger than the amount of sections \(layout(at: state).sections.count)")
}
return layout(at: state).sections[index]
}
Expand Down
73 changes: 0 additions & 73 deletions Example/.swiftlint.yml

This file was deleted.

1 change: 1 addition & 0 deletions Example/.swiftlint.yml
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
[![Version](https://img.shields.io/cocoapods/v/ChatLayout.svg?style=flat)](https://cocoapods.org/pods/ChatLayout)
[![Documentation](https://ekazaev.github.io/ChatLayout/badge.svg)](https://ekazaev.github.io/ChatLayout/)
[![Codecov](https://codecov.io/gh/ekazaev/ChatLayout/branch/master/graph/badge.svg)](https://codecov.io/gh/ekazaev/ChatLayout)
[![Codacy Badge](https://app.codacy.com/project/badge/Grade/b97c279a50984376ab2649f5a7d09e69)](https://www.codacy.com/gh/ekazaev/ChatLayout/dashboard?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=ekazaev/ChatLayout&amp;utm_campaign=Badge_Grade)
[![Swift Package Manager](https://img.shields.io/badge/SwiftPM-compatible-brightgreen.svg?style=flat)](https://github.com/apple/swift-package-manager)
[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BA51D.svg?style=flat)](https://github.com/Carthage/Carthage)
[![Swift 5.2](https://img.shields.io/badge/language-Swift5.2-orange.svg?style=flat)](https://developer.apple.com/swift)
Expand Down

0 comments on commit 22bb1b6

Please sign in to comment.