vtourraine / AcknowList

Acknowledgements screen displaying a list of licenses, for example from CocoaPods and Swift Package Manager dependencies.
MIT License
798 stars 60 forks source link

Add Swift Package Manager support #58

Closed curato-research closed 5 years ago

curato-research commented 5 years ago

I have been successfully added Acknowlist using SPM using this package.swift file.

1 thing though is that I'm not using the default localized strings, I'm not sure if they would work this way. But it might just solve #53.

vtourraine commented 5 years ago

Alright!

Sorry it took so long, but I’ve finally merged this in, and tagged it as a new release (1.9.2), so you can now install AcknowList with SPM from Xcode. 🎉

But we still have a couple of issues with SPM:

  1. No resources for localization: as far as I know, we can’t include a Bundle for the localization strings, and we’re waiting for an official SPM solution. Dedicated issue: #59
  2. Repo folders: this repo doesn’t use the default SPM folders structure (Sources, etc). We can still make it work with the path configuration, but the resulting package includes a lot of unnecessary files. Maybe we should take that opportunity to switch to the default SPM structure, and bump this library version number to AcknowList 2.0. Dedicated issue: #60
  3. Unit test: this is related to the files structure, I think, because if I try to define the test target in Package.swift, the package can’t run properly. If I re-organize the folders with the default structure, the tests run as expected (and mostly fail, because the resources are missing). Dedicated issue: #61

I’ve created GitHub issues for each of these problems. I really don’t have a lot of experience with SPM, so feel free to suggest better solutions for these challenges. Thanks!

vtourraine commented 5 years ago

(updated with GitHub issues references)