@mmerterden/multi-agent-pipeline 20.7.0 → 20.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/LICENSE +0 -10
- package/docs/facts.json +1 -1
- package/manifest.json +266 -267
- package/package.json +2 -2
- package/pipeline/scripts/_notices.mjs +1 -1
- package/pipeline/skills/.skill-manifest.json +68 -68
- package/pipeline/skills/shared/README.md +70 -70
- package/pipeline/skills/shared/external/alarmkit/SKILL.md +373 -381
- package/pipeline/skills/shared/external/alarmkit/evals/evals.json +23 -18
- package/pipeline/skills/shared/external/alarmkit/references/alarmkit-patterns.md +328 -378
- package/pipeline/skills/shared/external/app-clips/SKILL.md +260 -160
- package/pipeline/skills/shared/external/app-clips/evals/evals.json +27 -27
- package/pipeline/skills/shared/external/app-clips/references/data-handoff-notifications-location.md +150 -83
- package/pipeline/skills/shared/external/app-clips/references/routing-and-experiences.md +135 -83
- package/pipeline/skills/shared/external/app-clips/references/size-capabilities-and-promotion.md +143 -85
- package/pipeline/skills/shared/external/app-intents/SKILL.md +302 -304
- package/pipeline/skills/shared/external/app-intents/evals/evals.json +21 -21
- package/pipeline/skills/shared/external/app-intents/references/appintents-advanced.md +594 -894
- package/pipeline/skills/shared/external/app-store-optimization/SKILL.md +339 -277
- package/pipeline/skills/shared/external/app-store-optimization/evals/evals.json +27 -23
- package/pipeline/skills/shared/external/app-store-optimization/references/keyword-research-methodology.md +105 -122
- package/pipeline/skills/shared/external/app-store-optimization/references/product-page-variants.md +143 -166
- package/pipeline/skills/shared/external/app-store-review/SKILL.md +307 -326
- package/pipeline/skills/shared/external/app-store-review/evals/evals.json +21 -21
- package/pipeline/skills/shared/external/app-store-review/references/privacy-manifest.md +105 -67
- package/pipeline/skills/shared/external/app-store-review/references/review-checklists.md +114 -101
- package/pipeline/skills/shared/external/apple-on-device-ai/SKILL.md +333 -360
- package/pipeline/skills/shared/external/apple-on-device-ai/evals/evals.json +24 -27
- package/pipeline/skills/shared/external/apple-on-device-ai/references/coreml-conversion.md +215 -322
- package/pipeline/skills/shared/external/apple-on-device-ai/references/coreml-optimization.md +161 -256
- package/pipeline/skills/shared/external/apple-on-device-ai/references/foundation-models.md +277 -387
- package/pipeline/skills/shared/external/apple-on-device-ai/references/mlx-swift.md +196 -210
- package/pipeline/skills/shared/external/authentication/SKILL.md +265 -381
- package/pipeline/skills/shared/external/authentication/evals/evals.json +25 -25
- package/pipeline/skills/shared/external/authentication/references/keychain-biometric.md +133 -178
- package/pipeline/skills/shared/external/authentication/references/passkeys.md +111 -147
- package/pipeline/skills/shared/external/avkit/SKILL.md +267 -364
- package/pipeline/skills/shared/external/avkit/evals/evals.json +26 -26
- package/pipeline/skills/shared/external/avkit/references/avkit-patterns.md +375 -493
- package/pipeline/skills/shared/external/background-processing/SKILL.md +270 -382
- package/pipeline/skills/shared/external/background-processing/evals/evals.json +22 -22
- package/pipeline/skills/shared/external/background-processing/references/background-task-patterns.md +169 -317
- package/pipeline/skills/shared/external/callkit-voip/SKILL.md +290 -371
- package/pipeline/skills/shared/external/callkit-voip/evals/evals.json +24 -24
- package/pipeline/skills/shared/external/callkit-voip/references/callkit-patterns.md +175 -343
- package/pipeline/skills/shared/external/cloudkit-sync/SKILL.md +292 -381
- package/pipeline/skills/shared/external/cloudkit-sync/evals/evals.json +33 -30
- package/pipeline/skills/shared/external/cloudkit-sync/references/cloudkit-patterns.md +227 -355
- package/pipeline/skills/shared/external/contacts-framework/SKILL.md +197 -346
- package/pipeline/skills/shared/external/contacts-framework/evals/evals.json +19 -21
- package/pipeline/skills/shared/external/contacts-framework/references/contacts-patterns.md +169 -308
- package/pipeline/skills/shared/external/core-bluetooth/SKILL.md +226 -376
- package/pipeline/skills/shared/external/core-bluetooth/evals/evals.json +25 -22
- package/pipeline/skills/shared/external/core-bluetooth/references/ble-patterns.md +257 -337
- package/pipeline/skills/shared/external/core-data/SKILL.md +292 -368
- package/pipeline/skills/shared/external/core-data/evals/evals.json +30 -27
- package/pipeline/skills/shared/external/core-motion/SKILL.md +235 -324
- package/pipeline/skills/shared/external/core-motion/evals/evals.json +31 -27
- package/pipeline/skills/shared/external/core-motion/references/motion-patterns.md +210 -310
- package/pipeline/skills/shared/external/core-nfc/SKILL.md +292 -366
- package/pipeline/skills/shared/external/core-nfc/evals/evals.json +22 -24
- package/pipeline/skills/shared/external/core-nfc/references/nfc-patterns.md +233 -329
- package/pipeline/skills/shared/external/coreml/SKILL.md +323 -367
- package/pipeline/skills/shared/external/coreml/evals/evals.json +24 -21
- package/pipeline/skills/shared/external/coreml/references/coreml-swift-integration.md +562 -565
- package/pipeline/skills/shared/external/cryptokit/SKILL.md +253 -394
- package/pipeline/skills/shared/external/cryptokit/evals/evals.json +20 -18
- package/pipeline/skills/shared/external/cryptokit/references/cryptokit-patterns.md +299 -488
- package/pipeline/skills/shared/external/debugging-instruments/SKILL.md +270 -323
- package/pipeline/skills/shared/external/debugging-instruments/evals/evals.json +27 -30
- package/pipeline/skills/shared/external/debugging-instruments/references/instruments-guide.md +167 -315
- package/pipeline/skills/shared/external/debugging-instruments/references/lldb-patterns.md +140 -193
- package/pipeline/skills/shared/external/device-integrity/SKILL.md +230 -353
- package/pipeline/skills/shared/external/device-integrity/evals/evals.json +25 -21
- package/pipeline/skills/shared/external/device-integrity/references/device-integrity-patterns.md +159 -197
- package/pipeline/skills/shared/external/energykit/SKILL.md +225 -392
- package/pipeline/skills/shared/external/energykit/evals/evals.json +29 -28
- package/pipeline/skills/shared/external/energykit/references/energykit-patterns.md +174 -470
- package/pipeline/skills/shared/external/eventkit-calendar/SKILL.md +261 -383
- package/pipeline/skills/shared/external/eventkit-calendar/evals/evals.json +25 -22
- package/pipeline/skills/shared/external/eventkit-calendar/references/eventkit-patterns.md +165 -268
- package/pipeline/skills/shared/external/healthkit/SKILL.md +252 -303
- package/pipeline/skills/shared/external/healthkit/evals/evals.json +24 -23
- package/pipeline/skills/shared/external/healthkit/references/healthkit-patterns.md +369 -523
- package/pipeline/skills/shared/external/homekit-matter/SKILL.md +233 -348
- package/pipeline/skills/shared/external/homekit-matter/evals/evals.json +27 -22
- package/pipeline/skills/shared/external/homekit-matter/references/matter-commissioning.md +199 -305
- package/pipeline/skills/shared/external/ios-accessibility/SKILL.md +368 -340
- package/pipeline/skills/shared/external/ios-accessibility/evals/evals.json +28 -27
- package/pipeline/skills/shared/external/ios-accessibility/references/a11y-patterns.md +314 -260
- package/pipeline/skills/shared/external/ios-accessibility/references/media-accessibility.md +97 -67
- package/pipeline/skills/shared/external/ios-accessibility/references/nutrition-labels.md +165 -101
- package/pipeline/skills/shared/external/ios-localization/SKILL.md +258 -371
- package/pipeline/skills/shared/external/ios-localization/evals/evals.json +23 -23
- package/pipeline/skills/shared/external/ios-localization/references/formatstyle-locale.md +283 -491
- package/pipeline/skills/shared/external/ios-localization/references/string-catalogs.md +313 -440
- package/pipeline/skills/shared/external/ios-networking/SKILL.md +265 -341
- package/pipeline/skills/shared/external/ios-networking/evals/evals.json +24 -24
- package/pipeline/skills/shared/external/ios-networking/references/background-websocket.md +425 -652
- package/pipeline/skills/shared/external/ios-networking/references/file-storage-patterns.md +143 -285
- package/pipeline/skills/shared/external/ios-networking/references/lightweight-clients.md +93 -53
- package/pipeline/skills/shared/external/ios-networking/references/network-framework.md +231 -456
- package/pipeline/skills/shared/external/ios-networking/references/urlsession-patterns.md +517 -784
- package/pipeline/skills/shared/external/ios-simulator/SKILL.md +265 -393
- package/pipeline/skills/shared/external/ios-simulator/evals/evals.json +21 -21
- package/pipeline/skills/shared/external/ios-simulator/references/simctl-commands.md +177 -270
- package/pipeline/skills/shared/external/live-activities/SKILL.md +318 -360
- package/pipeline/skills/shared/external/live-activities/evals/evals.json +21 -21
- package/pipeline/skills/shared/external/live-activities/references/activitykit-patterns.md +478 -710
- package/pipeline/skills/shared/external/mapkit-location/SKILL.md +295 -267
- package/pipeline/skills/shared/external/mapkit-location/evals/evals.json +28 -24
- package/pipeline/skills/shared/external/mapkit-location/references/mapkit-corelocation-patterns.md +378 -532
- package/pipeline/skills/shared/external/mapkit-location/references/mapkit-patterns.md +397 -499
- package/pipeline/skills/shared/external/metrickit-diagnostics/SKILL.md +165 -348
- package/pipeline/skills/shared/external/metrickit-diagnostics/evals/evals.json +26 -23
- package/pipeline/skills/shared/external/metrickit-diagnostics/references/metrickit-patterns.md +123 -130
- package/pipeline/skills/shared/external/musickit-audio/SKILL.md +189 -315
- package/pipeline/skills/shared/external/musickit-audio/evals/evals.json +22 -21
- package/pipeline/skills/shared/external/musickit-audio/references/musickit-patterns.md +181 -270
- package/pipeline/skills/shared/external/natural-language/SKILL.md +188 -340
- package/pipeline/skills/shared/external/natural-language/evals/evals.json +21 -21
- package/pipeline/skills/shared/external/natural-language/references/translation-patterns.md +171 -225
- package/pipeline/skills/shared/external/passkit-wallet/SKILL.md +258 -392
- package/pipeline/skills/shared/external/passkit-wallet/evals/evals.json +30 -29
- package/pipeline/skills/shared/external/passkit-wallet/references/wallet-passes.md +164 -231
- package/pipeline/skills/shared/external/pdfkit/SKILL.md +312 -344
- package/pipeline/skills/shared/external/pdfkit/evals/evals.json +19 -19
- package/pipeline/skills/shared/external/pdfkit/references/pdfkit-patterns.md +413 -624
- package/pipeline/skills/shared/external/pencilkit-drawing/SKILL.md +242 -358
- package/pipeline/skills/shared/external/pencilkit-drawing/evals/evals.json +25 -21
- package/pipeline/skills/shared/external/pencilkit-drawing/references/pencilkit-patterns.md +161 -226
- package/pipeline/skills/shared/external/permissionkit/SKILL.md +282 -400
- package/pipeline/skills/shared/external/permissionkit/evals/evals.json +27 -30
- package/pipeline/skills/shared/external/permissionkit/references/permissionkit-patterns.md +237 -350
- package/pipeline/skills/shared/external/photos-camera-media/SKILL.md +276 -325
- package/pipeline/skills/shared/external/photos-camera-media/references/av-playback.md +299 -545
- package/pipeline/skills/shared/external/photos-camera-media/references/camera-capture.md +344 -588
- package/pipeline/skills/shared/external/photos-camera-media/references/image-loading-caching.md +316 -660
- package/pipeline/skills/shared/external/photos-camera-media/references/photokit-patterns.md +270 -416
- package/pipeline/skills/shared/external/push-notifications/SKILL.md +312 -340
- package/pipeline/skills/shared/external/push-notifications/evals/evals.json +27 -26
- package/pipeline/skills/shared/external/push-notifications/references/notification-patterns.md +328 -485
- package/pipeline/skills/shared/external/push-notifications/references/rich-notifications.md +327 -560
- package/pipeline/skills/shared/external/realitykit-ar/SKILL.md +218 -410
- package/pipeline/skills/shared/external/realitykit-ar/evals/evals.json +24 -27
- package/pipeline/skills/shared/external/realitykit-ar/references/realitykit-patterns.md +221 -348
- package/pipeline/skills/shared/external/shareplay-activities/SKILL.md +222 -393
- package/pipeline/skills/shared/external/shareplay-activities/evals/evals.json +23 -24
- package/pipeline/skills/shared/external/shareplay-activities/references/shareplay-patterns.md +280 -420
- package/pipeline/skills/shared/external/speech-recognition/SKILL.md +217 -421
- package/pipeline/skills/shared/external/speech-recognition/evals/evals.json +23 -26
- package/pipeline/skills/shared/external/speech-recognition/references/speechanalyzer-patterns.md +133 -125
- package/pipeline/skills/shared/external/storekit/SKILL.md +228 -204
- package/pipeline/skills/shared/external/storekit/evals/evals.json +27 -24
- package/pipeline/skills/shared/external/storekit/references/app-review-guidelines.md +98 -109
- package/pipeline/skills/shared/external/storekit/references/core-patterns.md +298 -242
- package/pipeline/skills/shared/external/storekit/references/storekit-advanced.md +356 -649
- package/pipeline/skills/shared/external/swift-api-design-guidelines/SKILL.md +274 -399
- package/pipeline/skills/shared/external/swift-api-design-guidelines/evals/evals.json +22 -24
- package/pipeline/skills/shared/external/swift-api-design-guidelines/references/argument-labels-and-parameters.md +107 -108
- package/pipeline/skills/shared/external/swift-api-design-guidelines/references/conventions-and-special-rules.md +93 -165
- package/pipeline/skills/shared/external/swift-api-design-guidelines/references/naming-and-clarity.md +99 -137
- package/pipeline/skills/shared/external/swift-api-design-guidelines/references/side-effects-and-mutating-pairs.md +77 -120
- package/pipeline/skills/shared/external/swift-architecture/SKILL.md +334 -350
- package/pipeline/skills/shared/external/swift-architecture/evals/evals.json +22 -22
- package/pipeline/skills/shared/external/swift-charts/SKILL.md +208 -394
- package/pipeline/skills/shared/external/swift-charts/evals/evals.json +27 -30
- package/pipeline/skills/shared/external/swift-charts/references/charts-patterns.md +351 -762
- package/pipeline/skills/shared/external/swift-codable/SKILL.md +339 -343
- package/pipeline/skills/shared/external/swift-codable/evals/evals.json +20 -20
- package/pipeline/skills/shared/external/swift-concurrency/SKILL.md +303 -351
- package/pipeline/skills/shared/external/swift-concurrency/evals/evals.json +27 -24
- package/pipeline/skills/shared/external/swift-concurrency/references/approachable-concurrency.md +65 -80
- package/pipeline/skills/shared/external/swift-concurrency/references/async-algorithms.md +48 -84
- package/pipeline/skills/shared/external/swift-concurrency/references/bridging-interop.md +134 -79
- package/pipeline/skills/shared/external/swift-concurrency/references/concurrency-patterns.md +145 -167
- package/pipeline/skills/shared/external/swift-concurrency/references/diagnostics.md +62 -50
- package/pipeline/skills/shared/external/swift-concurrency/references/swiftui-concurrency.md +92 -121
- package/pipeline/skills/shared/external/swift-concurrency/references/synchronization-primitives.md +177 -241
- package/pipeline/skills/shared/external/swift-formatstyle/SKILL.md +258 -234
- package/pipeline/skills/shared/external/swift-language/SKILL.md +342 -382
- package/pipeline/skills/shared/external/swift-language/evals/evals.json +24 -27
- package/pipeline/skills/shared/external/swift-language/references/swift-attributes-interop.md +79 -56
- package/pipeline/skills/shared/external/swift-language/references/swift-patterns-extended.md +297 -340
- package/pipeline/skills/shared/external/swift-security/SKILL.md +180 -161
- package/pipeline/skills/shared/external/swift-security/evals/evals.json +25 -25
- package/pipeline/skills/shared/external/swift-security/references/biometric-authentication.md +314 -469
- package/pipeline/skills/shared/external/swift-security/references/certificate-trust.md +408 -476
- package/pipeline/skills/shared/external/swift-security/references/common-anti-patterns.md +260 -530
- package/pipeline/skills/shared/external/swift-security/references/compliance-owasp-mapping.md +270 -477
- package/pipeline/skills/shared/external/swift-security/references/credential-storage-patterns.md +573 -571
- package/pipeline/skills/shared/external/swift-security/references/cryptokit-public-key.md +370 -441
- package/pipeline/skills/shared/external/swift-security/references/cryptokit-symmetric.md +332 -433
- package/pipeline/skills/shared/external/swift-security/references/keychain-access-control.md +346 -468
- package/pipeline/skills/shared/external/swift-security/references/keychain-fundamentals.md +352 -472
- package/pipeline/skills/shared/external/swift-security/references/keychain-item-classes.md +431 -432
- package/pipeline/skills/shared/external/swift-security/references/keychain-sharing.md +328 -425
- package/pipeline/skills/shared/external/swift-security/references/migration-legacy-stores.md +341 -579
- package/pipeline/skills/shared/external/swift-security/references/secure-enclave.md +396 -457
- package/pipeline/skills/shared/external/swift-security/references/testing-security-code.md +354 -614
- package/pipeline/skills/shared/external/swift-testing/SKILL.md +188 -175
- package/pipeline/skills/shared/external/swift-testing/evals/evals.json +26 -24
- package/pipeline/skills/shared/external/swift-testing/references/testing-advanced.md +80 -84
- package/pipeline/skills/shared/external/swift-testing/references/testing-patterns.md +317 -433
- package/pipeline/skills/shared/external/swiftdata/SKILL.md +392 -256
- package/pipeline/skills/shared/external/swiftdata/evals/evals.json +24 -24
- package/pipeline/skills/shared/external/swiftdata/references/core-data-coexistence.md +206 -402
- package/pipeline/skills/shared/external/swiftdata/references/indexing.md +59 -52
- package/pipeline/skills/shared/external/swiftdata/references/predicate-pitfalls.md +57 -33
- package/pipeline/skills/shared/external/swiftdata/references/swiftdata-advanced.md +354 -747
- package/pipeline/skills/shared/external/swiftdata/references/swiftdata-queries.md +300 -508
- package/pipeline/skills/shared/external/swiftlint/SKILL.md +175 -226
- package/pipeline/skills/shared/external/swiftlint/references/adoption-and-configuration.md +141 -208
- package/pipeline/skills/shared/external/swiftlint/references/custom-rules-and-analyze.md +100 -109
- package/pipeline/skills/shared/external/swiftlint/references/plugins-run-scripts-and-integrations.md +159 -179
- package/pipeline/skills/shared/external/swiftlint/references/rule-reference.md +383 -18
- package/pipeline/skills/shared/external/swiftlint/references/rules-suppressions-and-baselines.md +143 -229
- package/pipeline/skills/shared/external/swiftui-animation/SKILL.md +283 -366
- package/pipeline/skills/shared/external/swiftui-animation/references/animation-advanced.md +396 -608
- package/pipeline/skills/shared/external/swiftui-animation/references/core-animation-bridge.md +336 -385
- package/pipeline/skills/shared/external/swiftui-gestures/SKILL.md +239 -349
- package/pipeline/skills/shared/external/swiftui-gestures/references/gesture-patterns.md +228 -310
- package/pipeline/skills/shared/external/swiftui-layout-components/SKILL.md +260 -249
- package/pipeline/skills/shared/external/swiftui-layout-components/references/form.md +92 -74
- package/pipeline/skills/shared/external/swiftui-layout-components/references/grids.md +112 -177
- package/pipeline/skills/shared/external/swiftui-layout-components/references/list.md +61 -64
- package/pipeline/skills/shared/external/swiftui-layout-components/references/scrollview.md +94 -134
- package/pipeline/skills/shared/external/swiftui-liquid-glass/SKILL.md +193 -225
- package/pipeline/skills/shared/external/swiftui-liquid-glass/references/liquid-glass.md +173 -327
- package/pipeline/skills/shared/external/swiftui-navigation/SKILL.md +193 -168
- package/pipeline/skills/shared/external/swiftui-navigation/references/deeplinks.md +127 -150
- package/pipeline/skills/shared/external/swiftui-navigation/references/navigationstack.md +132 -133
- package/pipeline/skills/shared/external/swiftui-navigation/references/sheets.md +152 -117
- package/pipeline/skills/shared/external/swiftui-navigation/references/tabview.md +106 -140
- package/pipeline/skills/shared/external/swiftui-patterns/SKILL.md +316 -252
- package/pipeline/skills/shared/external/swiftui-patterns/references/architecture-patterns.md +341 -332
- package/pipeline/skills/shared/external/swiftui-patterns/references/deprecated-migration.md +547 -854
- package/pipeline/skills/shared/external/swiftui-patterns/references/design-polish.md +485 -537
- package/pipeline/skills/shared/external/swiftui-patterns/references/platform-and-sharing.md +417 -499
- package/pipeline/skills/shared/external/swiftui-performance/SKILL.md +213 -376
- package/pipeline/skills/shared/external/swiftui-performance/references/demystify-swiftui-performance-wwdc23.md +86 -175
- package/pipeline/skills/shared/external/swiftui-performance/references/optimizing-swiftui-performance-instruments.md +89 -195
- package/pipeline/skills/shared/external/swiftui-performance/references/understanding-hangs-in-your-app.md +95 -182
- package/pipeline/skills/shared/external/swiftui-performance/references/understanding-improving-swiftui-performance.md +71 -149
- package/pipeline/skills/shared/external/swiftui-performance/references/wwdc-session-sources.md +21 -27
- package/pipeline/skills/shared/external/swiftui-uikit-interop/SKILL.md +303 -295
- package/pipeline/skills/shared/external/swiftui-uikit-interop/references/hosting-migration.md +204 -387
- package/pipeline/skills/shared/external/swiftui-uikit-interop/references/representable-recipes.md +469 -683
- package/pipeline/skills/shared/external/swiftui-webkit/SKILL.md +140 -186
- package/pipeline/skills/shared/external/swiftui-webkit/references/loading-and-observation.md +75 -86
- package/pipeline/skills/shared/external/swiftui-webkit/references/local-content-and-custom-schemes.md +63 -60
- package/pipeline/skills/shared/external/swiftui-webkit/references/migration-and-fallbacks.md +69 -137
- package/pipeline/skills/shared/external/swiftui-webkit/references/navigation-and-javascript.md +95 -67
- package/pipeline/skills/shared/external/tipkit/SKILL.md +220 -335
- package/pipeline/skills/shared/external/tipkit/references/tipkit-patterns.md +356 -494
- package/pipeline/skills/shared/external/vision-framework/SKILL.md +260 -375
- package/pipeline/skills/shared/external/vision-framework/references/vision-requests.md +393 -515
- package/pipeline/skills/shared/external/vision-framework/references/visionkit-scanner.md +363 -539
- package/pipeline/skills/shared/external/weatherkit/SKILL.md +152 -310
- package/pipeline/skills/shared/external/weatherkit/references/weatherkit-patterns.md +288 -407
- package/pipeline/skills/shared/external/widgetkit/SKILL.md +216 -288
- package/pipeline/skills/shared/external/widgetkit/references/widgetkit-advanced.md +414 -719
- package/pipeline/skills/shared/external/NOTICE-swift-ios-skills.md +0 -39
|
@@ -1,35 +1,400 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Rule Reference, Grouped by Concern
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Back to [SKILL.md](../SKILL.md).
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
This is an offline index of every rule identifier, so you can find the right
|
|
6
|
+
name without a network connection. The summaries are short on purpose. For
|
|
7
|
+
exact behaviour, options, whether a rule is correctable, and any rule that has
|
|
8
|
+
moved between categories in a newer release, the rule directory
|
|
9
|
+
(https://realm.github.io/SwiftLint/rule-directory.html) and
|
|
10
|
+
`swiftlint rules <identifier>` are authoritative.
|
|
11
|
+
|
|
12
|
+
Kind column:
|
|
13
|
+
|
|
14
|
+
- **D**: default rule, on unless listed in `disabled_rules` (101 rules).
|
|
15
|
+
- **O**: opt-in rule, off until listed in `opt_in_rules` (149 rules).
|
|
16
|
+
- **A**: analyzer rule, needs the type-checked AST; list it in
|
|
17
|
+
`analyzer_rules` and run `swiftlint analyze --compiler-log-path <log>`
|
|
18
|
+
(5 rules). The workflow is in
|
|
19
|
+
[custom rules and analyze](custom-rules-and-analyze.md).
|
|
6
20
|
|
|
7
21
|
## Contents
|
|
8
22
|
|
|
9
|
-
- [
|
|
10
|
-
- [
|
|
11
|
-
- [
|
|
23
|
+
- [1. Controlling SwiftLint itself](#1-controlling-swiftlint-itself)
|
|
24
|
+
- [2. Size and complexity](#2-size-and-complexity)
|
|
25
|
+
- [3. Crash-prone constructs](#3-crash-prone-constructs)
|
|
26
|
+
- [4. Naming](#4-naming)
|
|
27
|
+
- [5. Access control](#5-access-control)
|
|
28
|
+
- [6. SwiftUI, assets and accessibility](#6-swiftui-assets-and-accessibility)
|
|
29
|
+
- [7. Concurrency and errors](#7-concurrency-and-errors)
|
|
30
|
+
- [8. Legacy and Objective-C era APIs](#8-legacy-and-objective-c-era-apis)
|
|
31
|
+
- [9. UIKit, Interface Builder and object lifetime](#9-uikit-interface-builder-and-object-lifetime)
|
|
32
|
+
- [10. Collections and sequences](#10-collections-and-sequences)
|
|
33
|
+
- [11. Idiomatic expressions](#11-idiomatic-expressions)
|
|
34
|
+
- [12. Redundant or dead code](#12-redundant-or-dead-code)
|
|
35
|
+
- [13. Types, declarations and file organisation](#13-types-declarations-and-file-organisation)
|
|
36
|
+
- [14. Enums and switch](#14-enums-and-switch)
|
|
37
|
+
- [15. Whitespace, braces and punctuation](#15-whitespace-braces-and-punctuation)
|
|
38
|
+
- [16. Multi-line layout](#16-multi-line-layout)
|
|
39
|
+
- [17. Comments and documentation](#17-comments-and-documentation)
|
|
40
|
+
- [18. Availability and deployment](#18-availability-and-deployment)
|
|
41
|
+
- [19. Testing](#19-testing)
|
|
42
|
+
- [20. Analyzer-only extras](#20-analyzer-only-extras)
|
|
43
|
+
|
|
44
|
+
## 1. Controlling SwiftLint itself
|
|
45
|
+
|
|
46
|
+
| Rule | Kind | Flags |
|
|
47
|
+
|---|---|---|
|
|
48
|
+
| `blanket_disable_command` | D | a `swiftlint:disable` that is never re-enabled and so covers the rest of the file |
|
|
49
|
+
| `invalid_swiftlint_command` | D | malformed `swiftlint:` comment directives |
|
|
50
|
+
| `superfluous_disable_command` | D | disable directives for rules that would not have fired there |
|
|
51
|
+
| `custom_rules` | D | umbrella identifier for the regex rules defined under `custom_rules` |
|
|
52
|
+
|
|
53
|
+
## 2. Size and complexity
|
|
54
|
+
|
|
55
|
+
| Rule | Kind | Flags |
|
|
56
|
+
|---|---|---|
|
|
57
|
+
| `line_length` | D | lines longer than the configured limit |
|
|
58
|
+
| `file_length` | D | files with too many lines |
|
|
59
|
+
| `type_body_length` | D | type bodies with too many lines |
|
|
60
|
+
| `function_body_length` | D | function bodies with too many lines |
|
|
61
|
+
| `closure_body_length` | O | closure bodies with too many lines |
|
|
62
|
+
| `function_parameter_count` | D | functions taking too many parameters |
|
|
63
|
+
| `enum_case_associated_values_count` | O | enum cases carrying too many associated values |
|
|
64
|
+
| `large_tuple` | D | tuples with too many members |
|
|
65
|
+
| `cyclomatic_complexity` | D | functions with too many independent branches |
|
|
66
|
+
| `nesting` | D | types or functions nested too deeply |
|
|
67
|
+
|
|
68
|
+
## 3. Crash-prone constructs
|
|
69
|
+
|
|
70
|
+
| Rule | Kind | Flags |
|
|
71
|
+
|---|---|---|
|
|
72
|
+
| `force_cast` | D | forced casts with `as!` |
|
|
73
|
+
| `force_try` | D | `try!` |
|
|
74
|
+
| `force_unwrapping` | O | force unwraps with postfix `!` |
|
|
75
|
+
| `implicitly_unwrapped_optional` | O | declarations typed as `T!` |
|
|
76
|
+
| `fatal_error_message` | O | `fatalError()` calls with no explanation |
|
|
77
|
+
| `discouraged_assert` | O | `assert(false, ...)` where `assertionFailure` says it directly |
|
|
78
|
+
| `unavailable_function` | O | stub functions that only trap and should be marked `@available(*, unavailable)` |
|
|
79
|
+
| `unowned_variable_capture` | O | `unowned` captures; `weak` is the safer default |
|
|
80
|
+
| `self_in_property_initialization` | D | stored property initialisers that refer to `self` without being `lazy` |
|
|
81
|
+
|
|
82
|
+
## 4. Naming
|
|
83
|
+
|
|
84
|
+
| Rule | Kind | Flags |
|
|
85
|
+
|---|---|---|
|
|
86
|
+
| `identifier_name` | D | variable, function and case names outside the allowed length or casing |
|
|
87
|
+
| `type_name` | D | type names outside the allowed length or casing |
|
|
88
|
+
| `generic_type_name` | D | generic parameter names outside the allowed length or casing |
|
|
89
|
+
| `inclusive_language` | D | identifiers that use terms flagged as non-inclusive |
|
|
90
|
+
| `discouraged_none_name` | O | cases or static members called `none`, which collide with `Optional.none` |
|
|
91
|
+
| `prefixed_toplevel_constant` | O | global constants lacking the configured prefix (such as `k`) |
|
|
92
|
+
| `file_name` | O | files whose name does not match the main type they declare |
|
|
93
|
+
| `file_name_no_space` | O | file names containing spaces |
|
|
94
|
+
|
|
95
|
+
## 5. Access control
|
|
96
|
+
|
|
97
|
+
| Rule | Kind | Flags |
|
|
98
|
+
|---|---|---|
|
|
99
|
+
| `explicit_acl` | O | declarations without an explicit access level |
|
|
100
|
+
| `explicit_top_level_acl` | O | top-level declarations without an explicit access level |
|
|
101
|
+
| `extension_access_modifier` | O | extensions whose members all share an access level that could sit on the extension |
|
|
102
|
+
| `no_extension_access_modifier` | O | any access modifier placed on an extension itself |
|
|
103
|
+
| `lower_acl_than_parent` | O | members declared more visible than the type that holds them |
|
|
104
|
+
| `private_over_fileprivate` | D | `fileprivate` where `private` would do |
|
|
105
|
+
| `strict_fileprivate` | O | every use of `fileprivate` |
|
|
106
|
+
| `redundant_set_access_control` | D | `private(set)` style setters that repeat the property's own level |
|
|
107
|
+
| `private_action` | O | `@IBAction` methods that are not private |
|
|
108
|
+
| `private_outlet` | O | `@IBOutlet` properties that are not private |
|
|
109
|
+
| `private_subject` | O | Combine subjects exposed beyond private scope |
|
|
110
|
+
| `private_swiftui_state` | O | SwiftUI state property wrappers that are not private |
|
|
111
|
+
|
|
112
|
+
## 6. SwiftUI, assets and accessibility
|
|
113
|
+
|
|
114
|
+
| Rule | Kind | Flags |
|
|
115
|
+
|---|---|---|
|
|
116
|
+
| `accessibility_label_for_image` | O | images with no accessibility label and not marked decorative |
|
|
117
|
+
| `accessibility_trait_for_button` | O | tap-handling views missing a button or link trait |
|
|
118
|
+
| `prefer_asset_symbols` | O | image lookups by string name where a generated asset symbol exists |
|
|
119
|
+
| `object_literal` | O | image and color initialisers that could be object literals |
|
|
120
|
+
| `discouraged_object_literal` | O | `#imageLiteral` / `#colorLiteral`; the mirror of `object_literal` |
|
|
121
|
+
|
|
122
|
+
## 7. Concurrency and errors
|
|
123
|
+
|
|
124
|
+
| Rule | Kind | Flags |
|
|
125
|
+
|---|---|---|
|
|
126
|
+
| `unhandled_throwing_task` | O | `Task` closures that throw with nobody catching or awaiting the error |
|
|
127
|
+
| `async_without_await` | O | functions marked `async` whose body never awaits |
|
|
128
|
+
| `incompatible_concurrency_annotation` | O | public concurrency annotations that need `@preconcurrency` to stay usable from older language modes |
|
|
129
|
+
| `redundant_sendable` | D | `Sendable` conformances on types that are already implicitly sendable, such as actor-isolated ones |
|
|
130
|
+
| `unneeded_throws_rethrows` | O | `throws` or `rethrows` on bodies that cannot throw |
|
|
131
|
+
| `untyped_error_in_catch` | O | `catch let error` with no pattern; plain `catch` already binds `error` |
|
|
132
|
+
|
|
133
|
+
## 8. Legacy and Objective-C era APIs
|
|
134
|
+
|
|
135
|
+
| Rule | Kind | Flags |
|
|
136
|
+
|---|---|---|
|
|
137
|
+
| `legacy_cggeometry_functions` | D | `CGRectGetWidth` style free functions instead of properties |
|
|
138
|
+
| `legacy_nsgeometry_functions` | D | the AppKit `NSRect` equivalents of the above |
|
|
139
|
+
| `legacy_constant` | D | old constants such as `CGRectZero` or `M_PI` |
|
|
140
|
+
| `legacy_constructor` | D | `CGPointMake` style constructors |
|
|
141
|
+
| `legacy_hashing` | D | overriding `hashValue` instead of implementing `hash(into:)` |
|
|
142
|
+
| `legacy_random` | D | `arc4random` family calls instead of `.random(in:)` |
|
|
143
|
+
| `legacy_multiple` | O | `value % n == 0` where `isMultiple(of:)` reads better |
|
|
144
|
+
| `legacy_objc_type` | O | bridged Foundation reference types where a Swift value type exists |
|
|
145
|
+
| `legacy_uigraphics_function` | O | `UIGraphicsBeginImageContext` style calls instead of `UIGraphicsImageRenderer` |
|
|
146
|
+
| `block_based_kvo` | D | string-keyed KVO instead of the key-path, closure-based API |
|
|
147
|
+
| `discouraged_direct_init` | D | types that should not be created with a bare `init()`, such as `UIDevice` or `Bundle` |
|
|
148
|
+
| `compiler_protocol_init` | D | direct calls to literal-protocol initialisers like `init(arrayLiteral:)` |
|
|
149
|
+
| `ns_number_init_as_function_reference` | D | passing `NSNumber.init` as a function value, which resolves ambiguously |
|
|
150
|
+
| `nsobject_prefer_isequal` | D | `NSObject` subclasses defining `==` instead of overriding `isEqual` |
|
|
151
|
+
| `dynamic_inline` | D | `dynamic` combined with `@inline(__always)` |
|
|
152
|
+
| `redundant_objc_attribute` | D | `@objc` that another attribute (such as `@IBAction`) already implies |
|
|
153
|
+
| `non_optional_string_data_conversion` | D | `string.data(using: .utf8)!` where `Data(string.utf8)` cannot fail |
|
|
154
|
+
| `optional_data_string_conversion` | D | `String(decoding:as:)`, which silently repairs invalid bytes, where the failable initialiser is safer |
|
|
155
|
+
|
|
156
|
+
## 9. UIKit, Interface Builder and object lifetime
|
|
157
|
+
|
|
158
|
+
| Rule | Kind | Flags |
|
|
159
|
+
|---|---|---|
|
|
160
|
+
| `class_delegate_protocol` | D | delegate protocols not restricted to classes, so they cannot be held weakly |
|
|
161
|
+
| `weak_delegate` | O | delegate properties not declared `weak` |
|
|
162
|
+
| `strong_iboutlet` | O | outlets declared `weak` instead of strong |
|
|
163
|
+
| `valid_ibinspectable` | D | `@IBInspectable` on unsupported types or without an explicit type |
|
|
164
|
+
| `ibinspectable_in_extension` | O | `@IBInspectable` declared inside extensions |
|
|
165
|
+
| `prohibited_interface_builder` | O | any outlet or action, for projects that build UI in code only |
|
|
166
|
+
| `notification_center_detachment` | D | removing observers other than `self` from `NotificationCenter` inside `deinit` |
|
|
167
|
+
| `discarded_notification_center_observer` | O | ignoring the token returned by block-based `addObserver` |
|
|
168
|
+
| `overridden_super_call` | O | overrides of lifecycle methods (for example `viewWillAppear`) that forget to call `super` |
|
|
169
|
+
| `prohibited_super_call` | O | overrides that must not call `super`, such as `loadView` |
|
|
170
|
+
| `override_in_extension` | O | overriding declarations placed in extensions |
|
|
171
|
+
| `required_deinit` | O | classes without an explicit `deinit` |
|
|
172
|
+
|
|
173
|
+
## 10. Collections and sequences
|
|
174
|
+
|
|
175
|
+
| Rule | Kind | Flags |
|
|
176
|
+
|---|---|---|
|
|
177
|
+
| `empty_count` | O | `.count == 0` instead of `.isEmpty` |
|
|
178
|
+
| `empty_collection_literal` | O | comparing against `[]` or `[:]` instead of `.isEmpty` |
|
|
179
|
+
| `empty_string` | O | comparing against `""` instead of `.isEmpty` |
|
|
180
|
+
| `contains_over_filter_count` | O | `filter { }.count > 0` instead of `contains(where:)` |
|
|
181
|
+
| `contains_over_filter_is_empty` | O | `filter { }.isEmpty` instead of `contains(where:)` |
|
|
182
|
+
| `contains_over_first_not_nil` | O | `first(where:) != nil` instead of `contains(where:)` |
|
|
183
|
+
| `contains_over_range_nil_comparison` | O | `range(of:) != nil` instead of `contains` |
|
|
184
|
+
| `first_where` | O | `filter { }.first` instead of `first(where:)` |
|
|
185
|
+
| `last_where` | O | `filter { }.last` instead of `last(where:)` |
|
|
186
|
+
| `sorted_first_last` | O | `sorted().first` instead of `min()` / `max()` |
|
|
187
|
+
| `flatmap_over_map_reduce` | O | `map { }.reduce([], +)` instead of `flatMap` |
|
|
188
|
+
| `reduce_into` | O | `reduce` building a copy-on-write value where `reduce(into:)` avoids copies |
|
|
189
|
+
| `reduce_boolean` | D | `reduce(true)` / `reduce(false)` instead of `allSatisfy` / `contains` |
|
|
190
|
+
| `is_disjoint` | D | `intersection(_:).isEmpty` instead of `isDisjoint(with:)` |
|
|
191
|
+
| `array_init` | O | `map { $0 }` used to copy a sequence into an array |
|
|
192
|
+
| `unused_enumerated` | D | `.enumerated()` where the index or the element is never used |
|
|
193
|
+
| `duplicated_key_in_dictionary_literal` | D | the same key twice in one dictionary literal |
|
|
194
|
+
| `joined_default_parameter` | O | `joined(separator: "")`, which is the default |
|
|
195
|
+
|
|
196
|
+
## 11. Idiomatic expressions
|
|
197
|
+
|
|
198
|
+
| Rule | Kind | Flags |
|
|
199
|
+
|---|---|---|
|
|
200
|
+
| `syntactic_sugar` | D | `Array<T>`, `Optional<T>` and similar spelled out instead of `[T]`, `T?` |
|
|
201
|
+
| `shorthand_operator` | D | `a = a + b` instead of `a += b` |
|
|
202
|
+
| `toggle_bool` | O | `flag = !flag` instead of `flag.toggle()` |
|
|
203
|
+
| `prefer_key_path` | O | `{ $0.name }` closures where `\.name` works |
|
|
204
|
+
| `prefer_type_checking` | D | `value as? T != nil` instead of `value is T` |
|
|
205
|
+
| `prefer_zero_over_explicit_init` | O | `CGPoint(x: 0, y: 0)` and friends instead of `.zero` |
|
|
206
|
+
| `prefer_condition_list` | O | `&&` in conditions where a comma-separated list works |
|
|
207
|
+
| `prefer_self_in_static_references` | O | spelling out the type name inside its own static context instead of `Self` |
|
|
208
|
+
| `prefer_self_type_over_type_of_self` | O | `type(of: self)` instead of `Self` |
|
|
209
|
+
| `explicit_init` | O | `.init` called explicitly where the type name alone works |
|
|
210
|
+
| `identical_operands` | O | comparisons with the same expression on both sides |
|
|
211
|
+
| `yoda_condition` | O | the constant on the left of a comparison |
|
|
212
|
+
| `for_where` | D | a lone `if` inside a `for` loop that could be a `where` clause |
|
|
213
|
+
| `shorthand_optional_binding` | O | `if let value = value` instead of `if let value` |
|
|
214
|
+
| `self_binding` | O | rebinding `self` under a name other than the configured one |
|
|
215
|
+
| `number_separator` | O | long numeric literals without `_` grouping |
|
|
216
|
+
| `no_magic_numbers` | O | unnamed numeric literals in code |
|
|
217
|
+
| `nslocalizedstring_key` | O | `NSLocalizedString` keys that are not static string literals |
|
|
218
|
+
| `nslocalizedstring_require_bundle` | O | `NSLocalizedString` calls without an explicit bundle |
|
|
219
|
+
| `optional_enum_case_matching` | O | matching optional enums with `.case?` where `.case` suffices |
|
|
220
|
+
| `pattern_matching_keywords` | O | `let` / `var` repeated per element instead of once outside the tuple pattern |
|
|
221
|
+
| `unavailable_condition` | D | `#available` with an empty true branch where `#unavailable` fits |
|
|
222
|
+
| `unused_optional_binding` | D | `if let _ = value` instead of `value != nil` |
|
|
223
|
+
| `void_function_in_ternary` | D | calling `Void` functions from the branches of a ternary |
|
|
224
|
+
| `anonymous_argument_in_multiline_closure` | O | `$0` style arguments in closures that span several lines |
|
|
225
|
+
| `shorthand_argument` | O | `$0` style arguments used far from the opening brace or in complex expressions |
|
|
226
|
+
| `trailing_closure` | O | a final closure argument passed inside the parentheses |
|
|
227
|
+
| `multiple_closures_with_trailing_closure` | D | trailing-closure syntax when more than one closure is passed |
|
|
228
|
+
|
|
229
|
+
## 12. Redundant or dead code
|
|
230
|
+
|
|
231
|
+
| Rule | Kind | Flags |
|
|
232
|
+
|---|---|---|
|
|
233
|
+
| `redundant_discardable_let` | D | `let _ = call()` instead of `_ = call()` |
|
|
234
|
+
| `redundant_nil_coalescing` | O | `?? nil` |
|
|
235
|
+
| `redundant_self` | O | explicit `self.` where it is not needed |
|
|
236
|
+
| `redundant_type_annotation` | O | type annotations the initial value already makes obvious |
|
|
237
|
+
| `redundant_string_enum_value` | D | string raw values identical to the case name |
|
|
238
|
+
| `redundant_void_return` | D | `-> Void` written on functions |
|
|
239
|
+
| `redundant_final` | O | `final` that adds nothing because the context is already final |
|
|
240
|
+
| `implicit_getter` | D | an explicit `get` in a read-only computed property |
|
|
241
|
+
| `implicit_optional_initialization` | D | optional variables with a spelled-out or missing `= nil`, according to the configured style |
|
|
242
|
+
| `implicit_return` | O | `return` in single-expression bodies |
|
|
243
|
+
| `direct_return` | O | assigning to a local only to return it on the next line |
|
|
244
|
+
| `superfluous_else` | O | `else` after a branch that already exits |
|
|
245
|
+
| `return_value_from_void_function` | O | `return someVoidCall()` in a `Void` function |
|
|
246
|
+
| `empty_parameters` | D | `(Void) -> T` instead of `() -> T` |
|
|
247
|
+
| `empty_parentheses_with_trailing_closure` | D | empty `()` before a trailing closure |
|
|
248
|
+
| `empty_enum_arguments` | D | `case .loaded(_)` where `case .loaded` suffices |
|
|
249
|
+
| `no_empty_block` | O | empty code blocks |
|
|
250
|
+
| `unneeded_break_in_switch` | D | `break` at the end of a case that already has code |
|
|
251
|
+
| `unneeded_escaping` | O | `@escaping` on closures that never escape |
|
|
252
|
+
| `unneeded_override` | D | overrides whose only statement calls `super` |
|
|
253
|
+
| `unneeded_synthesized_initializer` | D | hand-written initialisers identical to the synthesised memberwise one |
|
|
254
|
+
| `unneeded_parentheses_in_closure_argument` | O | parentheses around closure parameter lists that do not need them |
|
|
255
|
+
| `unused_closure_parameter` | D | closure parameters that are never used and could be `_` |
|
|
256
|
+
| `unused_parameter` | O | function parameters that are never used |
|
|
257
|
+
| `unused_control_flow_label` | D | loop or statement labels nobody jumps to |
|
|
258
|
+
| `unused_setter_value` | D | setters that ignore `newValue` |
|
|
259
|
+
| `unused_import` | A | imports the file does not need; correctable |
|
|
260
|
+
| `unused_declaration` | A | private declarations never referenced |
|
|
261
|
+
|
|
262
|
+
## 13. Types, declarations and file organisation
|
|
263
|
+
|
|
264
|
+
| Rule | Kind | Flags |
|
|
265
|
+
|---|---|---|
|
|
266
|
+
| `file_types_order` | O | top-level declarations in a file out of the configured order |
|
|
267
|
+
| `type_contents_order` | O | members inside a type out of the configured order |
|
|
268
|
+
| `one_declaration_per_file` | O | more than one top-level type in a file |
|
|
269
|
+
| `no_grouping_extension` | O | extensions of a type declared in the same file used only for grouping |
|
|
270
|
+
| `modifier_order` | O | declaration modifiers in an inconsistent order |
|
|
271
|
+
| `attributes` | O | attributes placed on the wrong line relative to their declaration |
|
|
272
|
+
| `attribute_name_spacing` | D | a space between an attribute name and its parentheses |
|
|
273
|
+
| `computed_accessors_order` | D | getter and setter written in inconsistent order |
|
|
274
|
+
| `protocol_property_accessors_order` | D | `{ set get }` instead of `{ get set }` in protocol requirements |
|
|
275
|
+
| `convenience_type` | O | structs or classes used only as namespaces that should be caseless enums |
|
|
276
|
+
| `static_operator` | O | operators declared as free functions instead of static members |
|
|
277
|
+
| `static_over_final_class` | D | `final class` members where `static` means the same |
|
|
278
|
+
| `non_overridable_class_declaration` | O | `class` members inside final classes that should be `static` or `final class` |
|
|
279
|
+
| `sorted_imports` | O | imports out of alphabetical order |
|
|
280
|
+
| `duplicate_imports` | D | the same module imported more than once |
|
|
281
|
+
| `function_default_parameter_at_end` | O | defaulted parameters placed before required ones |
|
|
282
|
+
| `discouraged_default_parameter` | O | default argument values in declarations where the rule discourages them; see the directory for its scope |
|
|
283
|
+
| `discouraged_optional_boolean` | O | `Bool?`, a three-state boolean |
|
|
284
|
+
| `discouraged_optional_collection` | O | optional arrays, sets and dictionaries where empty would do |
|
|
285
|
+
| `explicit_type_interface` | O | properties declared without an explicit type |
|
|
286
|
+
| `variable_shadowing` | O | local names that shadow an outer binding |
|
|
287
|
+
| `let_var_whitespace` | O | `let` / `var` declarations not separated from other statements by a blank line |
|
|
288
|
+
|
|
289
|
+
## 14. Enums and switch
|
|
290
|
+
|
|
291
|
+
| Rule | Kind | Flags |
|
|
292
|
+
|---|---|---|
|
|
293
|
+
| `duplicate_enum_cases` | D | two enum cases with the same name |
|
|
294
|
+
| `explicit_enum_raw_value` | O | raw-valued enum cases without an explicit raw value |
|
|
295
|
+
| `raw_value_for_camel_cased_codable_enum` | O | camel-cased cases of `Codable` string enums with no raw value, which would encode oddly |
|
|
296
|
+
| `required_enum_case` | O | enums conforming to a configured protocol but missing a required case |
|
|
297
|
+
| `sorted_enum_cases` | O | enum cases out of alphabetical order |
|
|
298
|
+
| `switch_case_alignment` | D | `case` labels not aligned with their `switch` |
|
|
299
|
+
| `switch_case_on_newline` | O | case bodies on the same line as the label |
|
|
300
|
+
| `vertical_whitespace_between_cases` | O | missing blank line between switch cases |
|
|
301
|
+
| `no_fallthrough_only` | D | cases whose only statement is `fallthrough` |
|
|
302
|
+
| `fallthrough` | O | any use of `fallthrough` |
|
|
303
|
+
| `duplicate_conditions` | D | the same condition twice in one `if` / `else if` chain or `switch` |
|
|
304
|
+
|
|
305
|
+
## 15. Whitespace, braces and punctuation
|
|
12
306
|
|
|
13
|
-
|
|
307
|
+
| Rule | Kind | Flags |
|
|
308
|
+
|---|---|---|
|
|
309
|
+
| `trailing_whitespace` | D | spaces or tabs at line end |
|
|
310
|
+
| `trailing_newline` | D | files not ending in exactly one newline |
|
|
311
|
+
| `leading_whitespace` | D | whitespace at the very start of a file |
|
|
312
|
+
| `trailing_semicolon` | D | semicolons at line end |
|
|
313
|
+
| `trailing_comma` | D | trailing commas in collection literals, per the configured preference |
|
|
314
|
+
| `vertical_whitespace` | D | too many consecutive blank lines |
|
|
315
|
+
| `vertical_whitespace_opening_braces` | O | a blank line right after `{` |
|
|
316
|
+
| `vertical_whitespace_closing_braces` | O | a blank line right before `}` |
|
|
317
|
+
| `opening_brace` | D | `{` not on the same line as its declaration, or missing a space before it |
|
|
318
|
+
| `contrasted_opening_brace` | O | the opposite style: `{` must start its own line |
|
|
319
|
+
| `closing_brace` | D | a space between `}` and a following `)` |
|
|
320
|
+
| `closure_spacing` | O | missing spaces just inside closure braces |
|
|
321
|
+
| `closure_end_indentation` | O | a closing `}` not aligned with the line that opened the closure |
|
|
322
|
+
| `closure_parameter_position` | D | closure parameters not on the line of the opening brace |
|
|
323
|
+
| `literal_expression_end_indentation` | O | a closing bracket of a multi-line literal not aligned with its start |
|
|
324
|
+
| `colon` | D | spaces before a colon or not exactly one after it |
|
|
325
|
+
| `comma` | D | a space before a comma or none after it |
|
|
326
|
+
| `comma_inheritance` | O | `&` in inheritance lists where commas belong |
|
|
327
|
+
| `control_statement` | D | parentheses around `if`, `guard`, `while` or `switch` conditions |
|
|
328
|
+
| `statement_position` | D | `else` or `catch` not on the same line as the preceding `}` |
|
|
329
|
+
| `return_arrow_whitespace` | D | wrong spacing around `->` |
|
|
330
|
+
| `operator_usage_whitespace` | O | missing spaces around binary operators |
|
|
331
|
+
| `no_space_in_method_call` | D | a space between a function name and its `(` |
|
|
332
|
+
| `function_name_whitespace` | D | irregular spacing between `func`, the name and its generic or parameter clause |
|
|
333
|
+
| `period_spacing` | O | more than one space after a period in comments |
|
|
334
|
+
| `indentation_width` | O | indentation that is not a multiple of the configured width |
|
|
335
|
+
| `invisible_character` | D | zero-width and similar invisible characters in string literals |
|
|
336
|
+
| `void_return` | D | `-> ()` instead of `-> Void` |
|
|
14
337
|
|
|
15
|
-
##
|
|
338
|
+
## 16. Multi-line layout
|
|
16
339
|
|
|
17
|
-
|
|
340
|
+
| Rule | Kind | Flags |
|
|
341
|
+
|---|---|---|
|
|
342
|
+
| `multiline_arguments` | O | call arguments that mix one-per-line with several-per-line |
|
|
343
|
+
| `multiline_arguments_brackets` | O | multi-line call arguments whose parentheses are not on their own lines |
|
|
344
|
+
| `multiline_call_arguments` | O | multi-line calls with more arguments per line than allowed |
|
|
345
|
+
| `multiline_function_chains` | O | chained calls that are neither all on one line nor one per line |
|
|
346
|
+
| `multiline_literal_brackets` | O | multi-line collection literals whose brackets share a line with elements |
|
|
347
|
+
| `multiline_parameters` | O | declaration parameters that mix one-per-line with several-per-line |
|
|
348
|
+
| `multiline_parameters_brackets` | O | multi-line parameter lists whose parentheses are not on their own lines |
|
|
349
|
+
| `vertical_parameter_alignment` | D | wrapped declaration parameters not aligned with the first |
|
|
350
|
+
| `vertical_parameter_alignment_on_call` | O | wrapped call arguments not aligned with the first |
|
|
351
|
+
| `conditional_returns_on_newline` | O | `return` on the same line as its `if` or `guard` |
|
|
352
|
+
| `collection_alignment` | O | keys or values in a multi-line collection literal not aligned |
|
|
18
353
|
|
|
19
|
-
|
|
354
|
+
## 17. Comments and documentation
|
|
20
355
|
|
|
21
|
-
|
|
356
|
+
| Rule | Kind | Flags |
|
|
357
|
+
|---|---|---|
|
|
358
|
+
| `todo` | D | `TODO` and `FIXME` comments |
|
|
359
|
+
| `expiring_todo` | O | dated TODO or FIXME comments that are close to or past their date |
|
|
360
|
+
| `mark` | D | badly formatted `// MARK:` comments |
|
|
361
|
+
| `comment_spacing` | D | `//` not followed by a space |
|
|
362
|
+
| `missing_docs` | O | public or open declarations without documentation |
|
|
363
|
+
| `orphaned_doc_comment` | D | `///` comments that are not attached to any declaration |
|
|
364
|
+
| `local_doc_comment` | O | doc comments inside function bodies, where a regular comment belongs |
|
|
365
|
+
| `file_header` | O | file headers that do not match the configured pattern |
|
|
22
366
|
|
|
23
|
-
##
|
|
367
|
+
## 18. Availability and deployment
|
|
24
368
|
|
|
25
|
-
|
|
369
|
+
| Rule | Kind | Flags |
|
|
370
|
+
|---|---|---|
|
|
371
|
+
| `deployment_target` | D | availability checks already satisfied by the deployment target |
|
|
26
372
|
|
|
27
|
-
|
|
373
|
+
## 19. Testing
|
|
28
374
|
|
|
29
|
-
|
|
375
|
+
| Rule | Kind | Flags |
|
|
376
|
+
|---|---|---|
|
|
377
|
+
| `xctfail_message` | D | `XCTFail()` with no message |
|
|
378
|
+
| `private_unit_test` | D | `private` test methods, which XCTest silently never runs |
|
|
379
|
+
| `balanced_xctest_lifecycle` | O | a `setUp` without a matching `tearDown`, or the reverse |
|
|
380
|
+
| `empty_xctest_method` | O | test methods with empty bodies |
|
|
381
|
+
| `final_test_case` | O | test case classes not marked `final` |
|
|
382
|
+
| `single_test_class` | O | more than one test class per file |
|
|
383
|
+
| `test_case_accessibility` | O | non-test members of a test class that are not private |
|
|
384
|
+
| `xct_specific_matcher` | O | `XCTAssertEqual(x, true)` style assertions where a specific matcher exists |
|
|
385
|
+
| `prefer_nimble` | O | XCTest assertions in codebases standardised on Nimble |
|
|
386
|
+
| `nimble_operator` | O | Nimble free-function matchers where an operator form exists |
|
|
387
|
+
| `quick_discouraged_call` | O | real work done directly inside Quick `describe` / `context` blocks |
|
|
388
|
+
| `quick_discouraged_focused_test` | O | focused Quick specs such as `fit` or `fdescribe` left in |
|
|
389
|
+
| `quick_discouraged_pending_test` | O | pending Quick specs such as `xit` left in |
|
|
30
390
|
|
|
31
|
-
## Analyzer
|
|
391
|
+
## 20. Analyzer-only extras
|
|
32
392
|
|
|
33
|
-
|
|
393
|
+
| Rule | Kind | Flags |
|
|
394
|
+
|---|---|---|
|
|
395
|
+
| `capture_variable` | A | closures that capture a mutable variable |
|
|
396
|
+
| `explicit_self` | A | instance member access without `self.` |
|
|
397
|
+
| `typesafe_array_init` | A | `Array(seq.map { ... })` where `map` already returns an array |
|
|
34
398
|
|
|
35
|
-
`
|
|
399
|
+
`unused_import` and `unused_declaration`, the other two analyzer rules, are
|
|
400
|
+
listed under redundant code above.
|