[NTV-609] Migrates SwiftSoup to SPM #1723
Merged
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.
π² What
As we migrate over to M1 machines for local development, we'll want to move over our Carthage dependencies into Xcode dependency manager where we can.
π€ Why
There are many benefits of using SPM over Carthage, but the main reason is to avoid handling manual compilation scripts to support multiple architecture types like this one found inside
carthage.sh
As you can see it's verbose, very cryptic, and we're not entirely sure if we can add M1 support to strings like
EXCLUDED_ARCHS
At least for now, we're going to move all dependencies that we can over to SPM that are listed inside the
Cartfile
.For now we'll do the 3rd party dependencies. There's also binaries which aren't built as schemas (the step failing on
make bootstrap
with M1 because of the code snippet above). Finally there's internal libraries that do get converted to schemas, which we might need to create custom SPM packages out of as we did withKickstarter-Prelude
.π How
SwiftSoup
fromCartfile
.SwiftSoup
fromCartfile.resolved
Kickstarter/Frameworks
folder and within each target.Carthage-xcfilelist
https://github.com/scinfu/SwiftSoup
to Package Dependencies version 2.0.0KsApi
targetimport SwiftSoup
, set breakpoints for where framework references are, run app and hit breakpoints. Continue running app and smoke tests where framework call sites occur.β Acceptance criteria
import KingFisher
and run the app on device to check the breakpoints are hit and the app continues to run as expected.