Problem
swiftlint --fix and the pinned swiftformat disagree on multiline-statement braces:
- swiftformat's
wrapMultilineStatementBraces wants the opening { on its own line.
- swiftlint's
opening_brace rule collapses it onto the condition line.
The swiftformat fixed-point is the CI gate (code-quality job → "SwiftFormat Check"); swiftlint's opening_brace is only a non-blocking warning. So running swiftlint --fix after swiftformat silently breaks formatting and fails CI.
Impact
Hit during PR #697 — swiftlint --fix re-collapsed two if let … { braces in WebHelpView.swift, failing the swiftformat CI check and costing a fix-up commit + CI re-run. It will recur for anyone who runs swiftlint --fix.
Fix options
- Disable
opening_brace in .swiftlint.yml (let swiftformat own brace style) — cleanest, one line.
- Document "run swiftformat last; never apply swiftlint's brace rewrites" (already a CLAUDE.md-adjacent gotcha) — weaker, relies on discipline.
Recommend option 1.
Problem
swiftlint --fixand the pinned swiftformat disagree on multiline-statement braces:wrapMultilineStatementBraceswants the opening{on its own line.opening_bracerule collapses it onto the condition line.The swiftformat fixed-point is the CI gate (
code-qualityjob → "SwiftFormat Check"); swiftlint'sopening_braceis only a non-blocking warning. So runningswiftlint --fixafter swiftformat silently breaks formatting and fails CI.Impact
Hit during PR #697 —
swiftlint --fixre-collapsed twoif let … {braces inWebHelpView.swift, failing the swiftformat CI check and costing a fix-up commit + CI re-run. It will recur for anyone who runsswiftlint --fix.Fix options
opening_bracein.swiftlint.yml(let swiftformat own brace style) — cleanest, one line.Recommend option 1.