|
| 1 | +# Name the file as below - will be hidden by nature |
| 2 | +# .tailor.yml |
| 3 | +# Rules reference - https://github.com/sleekbyte/tailor/wiki/Rules#constant-naming |
| 4 | + |
| 5 | + |
| 6 | +# // tailor:off |
| 7 | +# swift code - multiline |
| 8 | +# // tailor:on |
| 9 | + |
| 10 | +# single line // tailor:disable |
| 11 | + |
| 12 | + |
| 13 | +include: |
| 14 | + - SSSpinnerButton # Inspect all Swift files under "Spinner/" |
| 15 | + |
| 16 | +exclude: |
| 17 | + |
| 18 | +only: |
| 19 | +# class, enum, struct, and protocol names should follow UpperCamelCase naming convention : several words are joined together, and the first letter of every word is capitalized |
| 20 | + - upper-camel-case |
| 21 | + # method, var, and enum value names should follow lowerCamelCase naming convention: first letter of the entire word is lowercase, but subsequent first letters are uppercase. |
| 22 | + - lower-camel-case |
| 23 | +# Global constants should follow either UpperCamelCase or lowerCamelCase naming conventions. Local constants should follow lowerCamelCase naming conventions. |
| 24 | + - constant-naming |
| 25 | +# Prefer a single space before and after '->'. |
| 26 | + - arrow-whitespace |
| 27 | +# There should be no whitespace immediately before/after an opening chevron < and before the closing chevron >. |
| 28 | + - angle-bracket-whitespace |
| 29 | +# There should be no whitespace preceding the colon, exactly one whitespace after the colon for: var, class, struct, protocol, extension, func, and tuple declarations, dict literals and types & case statements |
| 30 | + - colon-whitespace |
| 31 | +# Prefer no spaces before and exactly one space after a comma (',') in the following structures: Identifier Lists, Switch Case Item Lists, Parameter Lists, Enum Case Lists, Array Literal Items |
| 32 | + - comma-whitespace |
| 33 | +# Prefer single space around operator in operator declarations. |
| 34 | + - operator-whitespace |
| 35 | +# Swift source files should terminate with exactly 1 \n character, not 0 nor more than 1. |
| 36 | + - terminating-newline |
| 37 | +# There should be no whitespace immediately before/after an opening parenthesis ( and before the closing parenthesis ). |
| 38 | +# NOT SUPPORTED - parentheses-whitespace |
| 39 | +# Flag whitespace after the last non-whitespace character on each line until the newline. |
| 40 | + # - trailing-whitespace |
| 41 | +# Prefer at least one whitespace character after a comment opening symbol (//, ///, /*, or /**) and at least one whitespace character before a comment closing symbol (*/). |
| 42 | + - comment-whitespace |
| 43 | +# Every function and method declaration should have one blank line before and after itself. An exception to this rule are functions that are declared at the start of a file (only need one blank line after their declaration) or at the end of a file (only need one blank line before their declaration). |
| 44 | + - function-whitespace |
| 45 | +# Enforce a line limit on the lengths of class bodies. |
| 46 | +# NOT SUPPORTED - max-class-length 1000 |
| 47 | +# Enforce a line limit on the lengths of closure bodies. |
| 48 | +# NOT SUPPORTED - max-closure-length 100 |
| 49 | +# Enforce a line limit on the lengths of function bodies. |
| 50 | +# NOT SUPPORTED - max-function-length 100 |
| 51 | +# Enforce a character limit on the length of each line. |
| 52 | +# NOT SUPPORTED - max-line-length 1000 |
| 53 | +# Enforce a character limit on the maximum length of each construct name for classes, enums, enumcases, structs, protocols, elements, functions, labels, setters, typealiases, types, variables, and constants. |
| 54 | +# NOT SUPPORTED - max-name-length 100 |
| 55 | +# Enforce a character limit on the minimum length of each construct name for classes, enums, enumcases, structs, protocols, elements, functions, labels, setters, typealiases, types, variables, and constants. |
| 56 | +# NOT SUPPORTED - min-name-length 5 |
| 57 | +# should follow the One True Brace Style (1TBS) |
| 58 | + - brace-style |
| 59 | +# NEVER DISABLE - void using the forced form of the type cast operator (as!) because Swift is not able to determine at compile time if the type conversion will succeed. |
| 60 | + - forced-type-cast |
| 61 | +# Multiple import statements should not be defined on a single line. |
| 62 | + - multiple-imports |
| 63 | +# NEVER DISABLE - TODO comments should be defined separately using non-nested single line comments. They should adhere to the <TODO: description> or <TODO(developer-name): description> syntax. |
| 64 | + - todo-syntax |
| 65 | +# Optional binding lists should not have consecutive var/let bindings. All constants must be preceded by at most one let binding. All variables must be preceded by only one var binding. |
| 66 | +# NOT SUPPORTED - redundant-optional-binding |
0 commit comments