Skip to content

feat: add Swift Package Manager support for iOS#61

Open
nicklasl wants to merge 1 commit into
mainfrom
nicklasl/add-spm-support
Open

feat: add Swift Package Manager support for iOS#61
nicklasl wants to merge 1 commit into
mainfrom
nicklasl/add-spm-support

Conversation

@nicklasl

@nicklasl nicklasl commented Jun 5, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds Package.swift manifest so the iOS plugin resolves via SPM (Flutter 3.44+ default)
  • Moves plugin Swift source to SPM-expected directory layout (ios/confidence_flutter_sdk/Sources/)
  • Updates podspec to reference new source paths while maintaining CocoaPods backward compatibility
  • Existing CI workflow unchanged — submodule copy still provides Confidence sources for CocoaPods builds

Test plan

  • CocoaPods: flutter build ios --no-codesign succeeds
  • SPM: swift package resolve resolves confidence-sdk-swift at 1.5.0
  • CI: verify existing iOS integration test passes
  • Manual: test with a Flutter 3.44+ project using SPM

🤖 Generated with Claude Code

Add Package.swift manifest so the iOS plugin resolves via SPM
(Flutter 3.44+ default) while keeping CocoaPods backward compat.

- Move plugin source to SPM-expected layout
- Add FlutterFramework dependency required by Flutter 3.41+
- Vendor Confidence sources via CI (same as CocoaPods path)
- Add SPM build check to CI matrix

Workaround: Flutter bug #186881 causes SPM identity mismatch when
repo name differs from plugin name. CI copies the plugin to /tmp
without git context to simulate the pub.dev install path.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@nicklasl nicklasl force-pushed the nicklasl/add-spm-support branch from b9b3f79 to 3480094 Compare June 9, 2026 12:18
@nicklasl nicklasl marked this pull request as ready for review June 9, 2026 12:18
@nicklasl nicklasl closed this Jun 10, 2026
@nicklasl nicklasl reopened this Jun 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant