Goal
Add CI (GitHub Actions) to the project so that every push / PR runs the build, tests, lint, and docs generation. Currently there is no automated verification.
Context
See the investigation report at docs/investigations/swift6-concurrency-audit-2026-05-13.md, Preventive Measures section. The audit recommends several "shift-left" guardrails that only pay off when wired into CI:
swift build + swift test under -strict-concurrency=complete
- SwiftLint custom rules banning
@unchecked Sendable and @preconcurrency import outside Sources/ReliaBLEMock/
- DocC build (
swift package generate-documentation) so public-API renames break the docs build, not silent drift
- (Future) test coverage reporting
Deliverable
.github/workflows/ci.yml triggered on PRs and pushes to main:
- Run
swift build and swift test on macOS-15 (or latest, matching iOS 18+ / macOS 15+ targets).
- Run SwiftLint with custom rules from the investigation report's Preventive Measures section.
- Run
swift package generate-documentation (see sub-issue) and fail on warnings.
- SwiftLint config (
.swiftlint.yml) with the custom rules:
custom_rules:
no_unchecked_sendable:
name: "@unchecked Sendable banned"
regex: '@unchecked\s+Sendable'
included: "Sources/ReliaBLE/.*\\.swift"
severity: error
no_preconcurrency_import:
name: "@preconcurrency import banned"
regex: '@preconcurrency\s+import'
included: "Sources/ReliaBLE/.*\\.swift"
severity: error
- Branch protection (manual step, document in this issue): require CI to pass on PRs to
main.
Sub-issues
- DocC build in CI (separate sub-issue tracked below).
Acceptance criteria
- A green CI badge appears in
README.md.
- Opening a PR triggers all three checks (build/test, lint, docs) and they pass on the current
main.
- Branch protection enforces passing CI before merge to
main.
References
Goal
Add CI (GitHub Actions) to the project so that every push / PR runs the build, tests, lint, and docs generation. Currently there is no automated verification.
Context
See the investigation report at
docs/investigations/swift6-concurrency-audit-2026-05-13.md, Preventive Measures section. The audit recommends several "shift-left" guardrails that only pay off when wired into CI:swift build+swift testunder-strict-concurrency=complete@unchecked Sendableand@preconcurrency importoutsideSources/ReliaBLEMock/swift package generate-documentation) so public-API renames break the docs build, not silent driftDeliverable
.github/workflows/ci.ymltriggered on PRs and pushes tomain:swift buildandswift teston macOS-15 (or latest, matchingiOS 18+ / macOS 15+targets).swift package generate-documentation(see sub-issue) and fail on warnings..swiftlint.yml) with the custom rules:main.Sub-issues
Acceptance criteria
README.md.main.main.References
docs/investigations/swift6-concurrency-audit-2026-05-13.md(Preventive Measures)