feat: add CocoaPods support via PolyMessaging.podspec#14
Merged
Conversation
Add a podspec so the SDK can be installed through CocoaPods (Trunk),
alongside the existing SwiftPM/Xcode/XcodeGen options.
- PolyMessaging.podspec: source-only, dependency-free, Apache-2.0,
iOS 15 / macOS 12, source tagged v#{version}.
- README: new 'Option 4 — CocoaPods' install snippet; bump stale
0.5.1 version pins to 0.6.0 across the Install section.
- CONTRIBUTING: release flow now bumps the podspec version in lockstep
with Version.swift/CHANGELOG.md and adds a 'pod trunk push' step.
Add a podspec-lint job running 'pod lib lint --allow-warnings' on macos-14 so the podspec can't silently rot. --allow-warnings because the SDK build emits non-fatal compiler warnings the lint would otherwise treat as errors.
Use the org-owned, readable mailbox that will own the pod on Trunk.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds CocoaPods as a distribution channel alongside SwiftPM. The SDK is a good fit: source-only, dependency-free, and it only imports system frameworks (auto-linked by Swift), so the podspec is minimal — no
resource_bundles, nos.dependency, noframeworksdeclarations needed.Decision: publish via CocoaPods Trunk so consumers can write
pod 'PolyMessaging', '~> 0.6'.Changes
PolyMessaging.podspec(new) — Apache-2.0, iOS 15 / macOS 12,swift_version 5.9,source_files = 'Sources/PolyMessaging/**/*.swift', source pinned to:tag => "v#{s.version}"(matches the existingvX.Y.Ztag convention).0.5.1version pins to0.6.0across the Install section (Xcode / SwiftPM / XcodeGen).Version.swift+CHANGELOG.md, and adds apod trunk pushstep (after tagging, so:tagresolves).Versioning note
The podspec adds a third place the version lives. It must mirror
Version.swiftexactly; this is now documented in the release checklist. (CocoaPods can't read the Swift literal, so it's a manual sync — flagging in case we'd rather script it later.)Validation
ruby -c PolyMessaging.podspec→ Syntax OKswift build→ cleanpod lib lintnot run — CocoaPods isn't installed in this environment. Should be run before merge/publish:pod lib lint PolyMessaging.podspecFollow-ups (not in this PR)
pod trunk register <email>before the first publish.pod lib lintso the spec can't rot.