Search code examples
xcodexcode7osx-elcapitan

How to make a CocoaPods project work on OS X El Capitan & Xcode 7 Beta?


I've updated to OS X El Capitan & Xcode 7 Beta released today and now my CocoaPods projects no longer work because of the new Swift syntax requirements. The automated Xcode project update breaks the code. Has anyone already figured this out already? Thanks.


Solution

  • Until Cocoapods supports Swift 2, at the very least you should be able to continue to use Xcode 6 until it does. If Xcode 7 has stomped all over your Cocoapods already, this link shows you how to clean it up https://gist.github.com/mbinna/4202236.

    Basically, from inside any project using Cocoapods:

    rm -rf "${HOME}/Library/Caches/CocoaPods"
    rm -rf "`pwd`/Pods/"
    pod update
    

    Then rebuild using Xcode 6 and everything should be back to normal.