Skip to content
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

SPM compatibility fixes, re-org: WIP #4

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

DanBurkhardt
Copy link

Hi. I have forked your fork and done some re-organization and compatibility expansion. There are a lot of changes in the top-line numbers, but that is mostly due to having duplicated example projects. Mostly this is a deletion / re-organization effort because I like the FW and need SPM support.

This is a draft PR: I am opening this to see if you would like to merge the changes / support the direction I am taking this.

Here is the TL;DR:

  • I re-implemented swiftPM compatibility because it was totally busted
  • Fixed Package.swift: mostly cleanup but it would not build until I upped the swift tools version
    • not sure what was corrupted here, tbh.
  • Replaced the Swift Package Manager + Example project workspace with a non-corrupted implementation
    • it would not even open with Xcode 14 👀
  • created a new forked "Examples" directory so SPM and Cocoapods examples can co-exist
  • updated the package name to reflect "ContainerController" without the Swift on the end (redundant)
  • fully tested and all working properly with Swift Package Manager implementation



Cocoapods, however, still has some import issues, this is a WIP but will address in a subsequent push.

Options for fixing Cocoapods support without maintaining two example projects:

  1. Leverage the working SPM directory path for all the files shared between the two projects. Essentially:
  • delete all files from the cocoapods dir and pod deinit
  • open the .xcproj file
  • leverage the SPM implementation and re-import all files a relative path to the SPM directory
  1. Move the files out of the SPM dir so they live in a 'shared' dir at the Examples/ folder level
  • Then re-link all of the files in both examples using relative paths to the 'shared' dir

There is another issue: naming. Idk what the situation is on Cocoapods, but the name collision issues don't necessarily exist when using the framework via SPM because you pull it straight from the repo. As long as you don't use two packages of the same name. Anyway, will propose solution in a future update to the Cocoapods example-- curious to hear any opinions you may have as well of course.

DanBurkhardt and others added 3 commits October 20, 2022 00:23
…d a new forked directory so SPM and Cocoapods examples can co-exist, updated the package name to reflect "ContainerController" without the Swift on the end (redundant), fully tested functioning with SPM, Cocoapods has some import issues, is WIP
@rivera-ernesto
Copy link
Member

Thanks a lot! Could you please sort out the conflicts so that we can consolidate it all?

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.

2 participants