How to download Podspec dependencies for local development

This is similar to what needs to be done very easily. I do not know why I simply cannot find a simple answer to this question.

I am creating a pod library that has a pod dependency.

So, in mine .podspecI have s.dependency 'SomePod', '~> 1.0'. Since I am writing my library with SomePod, I want the source files to be imported in order to import and use it. Of course, one way to do this is to have the PodFile in the repo and then install SomePod.

But is there any other way to load the dependency SomePodso that I can use it in my library? What is our best practice to have a clean structure?

FYI, I use the Cookie Cutter library to create my entire project structure. What I have to do is download these podspec dependencies and avoid using Podfile and pod install, since I already have the .xcworkspace generated from Cookie Cutter, so installing pod will not like it and it will go crazy.

+6
source share
1 answer

Well, you can handle dependency management with other tools (Carthage, etc.) or just on your own (git clone + project integration), but since you already provide podspec for your library, why not just stick with cocoapods for integration third-party libraries?

, , , SomePod , podspec call pod install.

:

  • lib
  • , SomePod, ( ).
+5

Source: https://habr.com/ru/post/1016079/


All Articles