-
Notifications
You must be signed in to change notification settings - Fork 59
Add Swift Package Manager (SPM) support for Flutter-SDK #356
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
reshab-code
wants to merge
13
commits into
develop
Choose a base branch
from
task/SDK-5694-spm-support-flutter-sdk
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
6a01613
Merge pull request #334 from CleverTap/develop
KambleSonam 7cb4deb
Merge pull request #336 from CleverTap/develop
Anush-Shand 6abef66
Merge pull request #339 from CleverTap/develop
Anush-Shand c6dca65
Merge pull request #343 from CleverTap/develop
Anush-Shand 2b6ceba
Merge pull request #345 from CleverTap/develop
KambleSonam cccb271
Merge pull request #350 from CleverTap/develop
Anush-Shand b3d30e8
Create Package.swift file for spm support
reshab-code 2a7a415
Create symlinks for spm
reshab-code 5d96862
Add guard to obj c imports in ClevertapPlugin.m
reshab-code 203c1e3
wrapped both CTJsonTemplateProducer.h and CTCustomTemplatesManager.h …
reshab-code b91d176
Narrowed header files in podspec
reshab-code c0b7ecf
Relocate Package.swift to ios/clevertap_plugin/ for Flutter SPM detec…
reshab-code dfd2cf9
Add swift package name under ios in pubspec.yaml, added guards for th…
reshab-code File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../CleverTapPlugin.h |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../CleverTapPluginAppFunctionPresenter.h |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../CleverTapPluginCustomTemplates.h |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../CleverTapPluginTemplatePresenter.h |
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../Classes |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| // swift-tools-version: 5.9 | ||
| import PackageDescription | ||
|
|
||
| let package = Package( | ||
| name: "clevertap_plugin", | ||
| platforms: [ | ||
| .iOS("12.0") | ||
| ], | ||
| products: [ | ||
| .library(name: "clevertap-plugin", targets: ["clevertap_plugin"]) | ||
| ], | ||
| dependencies: [ | ||
| .package( | ||
| url: "https://github.com/CleverTap/clevertap-ios-sdk", | ||
| from: "7.6.0" | ||
| ) | ||
| ], | ||
| targets: [ | ||
| .target( | ||
| name: "clevertap_plugin", | ||
| dependencies: [ | ||
| .product(name: "CleverTapSDK", package: "clevertap-ios-sdk") | ||
| ], | ||
| path: "Classes", | ||
| publicHeadersPath: "include", | ||
| cSettings: [ | ||
| .headerSearchPath("include"), | ||
| .headerSearchPath(".") | ||
| ] | ||
| ) | ||
| ] | ||
| ) |
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
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.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: CleverTap/clevertap-flutter
Length of output: 821
Align the CleverTap iOS SDK version constraints across CocoaPods and SwiftPM.
ios/clevertap_plugin.podspecpinsCleverTap-iOS-SDKto exact7.6.0, whileios/clevertap_plugin/Package.swiftuses SwiftPMfrom: "7.6.0"forclevertap-ios-sdk—so the same Flutter plugin can build against different CleverTapSDK versions depending on whether CocoaPods or SwiftPM is used. Make both package managers follow the same version policy (pin both sides to the same exact version, or use equivalent ranges).🤖 Prompt for AI Agents
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@reshab-code for cocoapods, we pin an exact version of the core-sdk. For SPM, do the same, using "from" in Package.swift will make the flutter sdk support all future versions. Look for the equivalent mechanism in SPM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure @akashvercetti , should we keep 7.6.0 which is the same for CocoaPods or the latest one ?