Files
OSGKeyboard/.swiftlint.yml
Rocky 498f407585 feat(account): add managed credits and cloud gateway
Introduce optional Apple account-backed credits with scoped gateway access while preserving local and BYOK paths. Refresh assistant behavior, tests, privacy disclosures, docs, and the website for the 2.0 experience.
2026-08-20 11:43:21 +08:00

74 lines
1.7 KiB
YAML

# SwiftLint configuration for OSGKeyboard
# Goal: simple, opinionated, minimal false positives
disabled_rules:
- trailing_whitespace
- line_length
- todo
- function_body_length
- type_body_length
- file_length
- cyclomatic_complexity
- force_cast
- force_try
# Existing code intentionally treats invalid UTF-8 as a recoverable parse
# failure rather than replacing bytes with U+FFFD.
- non_optional_string_data_conversion
# Guard-style loop bodies are clearer than compound `where` clauses in the
# text-processing state machines used throughout the project.
- for_where
# SwiftUI initializers commonly expose two or more closure parameters.
- multiple_closures_with_trailing_closure
opt_in_rules:
- empty_count
- first_where
- explicit_init
- prefer_self_type_over_type_of_self
- sorted_imports
- implicit_optional_initialization
# Algorithmic code uses conventional one- and two-letter local coordinates
# (`x`, `y`, `dx`, `i`) while public names remain descriptive.
identifier_name:
min_length:
warning: 1
max_length:
warning: 50
# These limits flag genuinely unwieldy declarations without rejecting common
# SwiftUI geometry tuples, dependency initializers, or nested Codable payloads.
type_name:
max_length:
warning: 50
large_tuple:
warning: 7
error: 9
function_parameter_count:
warning: 12
error: 15
nesting:
type_level:
warning: 3
function_level:
warning: 5
included:
- OSGKeyboard
- OSGKeyboardExt
- OSGKeyboardShared
- OSGKeyboardHostSupport
- OSGKeyboardMac
- OSGKeyboardTests
- OSGKeyboardExtTests
- OSGKeyboardMacTests
- OSGKeyboardUITests
- Tests
excluded:
- build
- DerivedData
- .build
- Pods
- Carthage