CocoaPods and Carthage

Carthage and CocoaPods are very different in terms of building the dependencies and integrating them in the project.

CocoaPods is centralized dependency manager and it will build your dependencies and integrate them directly in the project by creating new .xcworkspace workspace. This means that you get access to the build dependencies right after building.

Carthage on the other hand is decentralized dependency manager and it leaves you with the task of integrating the dependencies into your project. Carthage builds the frameworks specified in Cartfile and moves them to Carthage/Builds folder. After the build process it’s up to you to integrate and manage the dependencies.

In your case, when you build your PureLayout dependency with CocoaPods and Carthage, CocoaPods integrated it to project and Carthage left you with builds in Carthage/Builds which means that you used only CocoaPods build version of PureLayout.

Also, it’s a bad practice to use multiple package/dependency managers. You should stick to the one and be comfortable with it.

Leave a Comment