[WIP] Separate ReceiptParser into SPM#2062
Conversation
|
Turns out this approach might not be supported: https://forums.swift.org/t/unable-to-integrate-a-remote-package-that-has-local-packages/53146/5 Might have to keep the folder structure the same, and instead expose a separate target in the main We get the same result, but I was excited about this approach because it would allow creating many more smaller SPMs that would help us keep different parts of the SDK isolated like we do in Android. |
8a93941 to
5b6d5a8
Compare
d8cb2e9 to
8966da4
Compare
8966da4 to
4be52c8
Compare
907e85b to
1dc251b
Compare
1dc251b to
694b009
Compare
| targets: resolveTargets() | ||
| targets: [ | ||
| .target(name: "RevenueCat", | ||
| dependencies: [.byName(name: "ReceiptParser")], |
There was a problem hiding this comment.
In my experience, this will complicate things quite a bit.
It's a total headache to manage imports from a local package, we had something like this back in the objc days with PurchasesCoreSwift and it broke hybrids in all sorts of ways.
I think we should just have these two be independent packages, which just happen to have the same files.
If you use RC, you don't need the ReceiptParser package. If you use the ReceiptParser package, and you want to move to the full RevenueCat, you need to remove ReceiptParser and replace it with RevenueCat.
There was a problem hiding this comment.
One bummer with this is that SPM from Xcode might prompt you to install both by default, right?
There was a problem hiding this comment.
I think we should just have these two be independent packages, which just happen to have the same files.
That's a great idea, which will simplify this tremendously.
I wanted to have a call with you to discuss the approach, but thanks for providing the best path forward already :D
There was a problem hiding this comment.
happy to chat about it whenever!
|
New approach: #2096. |
Fixes [CSDK-17]. New approach after #2062.
Fixes [CSDK-17]. New approach after #2062.


Fixes CSDK-17
TODO:
- [ ] Create separate SPM for shared types (This would be a pain to do with CocoaPodsLogger?)APITestersCarthageintegration still worksREADMEReceiptParsertests to SPM (includeNSData+RCExtensionsTests: improved errors #2043)Loggeroutside modulerelease-checksall pass