-
Notifications
You must be signed in to change notification settings - Fork 951
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
Add support for SwiftPM #291
Conversation
1f403f2
to
4df7116
Compare
I will get this reviewed and merged first thing tomorrow! Just want to run through some of the tests since it looks like they have changed. Also, I’m not up to date on SPM... do I need to advertise/list it anywhere? Thanks! |
IMO it should be mentioned in Readme file as part of installation and emphasize on including bundle manually until adding resource capability is available in SwiftPM. Especially because it causes a crash if you don’t and use any of the APIs using the localization. |
Haven't forgotten about you! Had a few things come up at work, so might be closer to the weekend. |
No hurries, whenever you get to it, let me know if you had any questions. I’m still waiting for new Xcode11.4 beta to comes out to see if it’ll include resource changes. |
any updates on this? |
You can use |
For future reference, https://github.com/maniramezan/DateTools/tree/mani_swiftpm_5_3 contains the work for using SwiftPM 5.3 tooling which supports resources. For now, that branch breaks cocoapods and Carthage integrations due to lack of support for |
Closing this in favor of #294 |
This PR is adding support for SwiftPM. At the moment, the tests compile, but crashes when you run due to
DateTools.bundle
not being in the final bundle. Adding resources file to swiftpm has been recently added in SE-0271, but at the time of submitting this PR, it's not included in any available Swift snapshots or Xcode11.4b1 version. When it lands in public, the tests can be fixed also in addition to addingDateTools.bundle
as a resource. This is similar to #285 PR.Just note that for using SwiftPM at the moment, developers need to add
DateTools.bundle
manually to their codebase. Might worth to also update Readme file to mention SwiftPM integration and the necessity of adding the bundle file.