Search code examples
iosxcodedropboxcocoapodsbolts-framework

Cocoapods requires update each time on different computers through dropbox sync for bolts framework


My setup:

  • Xcode Project inside dropbox folder
  • Cocoapods installed
  • Parse is in my podfile which requires the Bolts framework

Every time I load up the workspace after having edited it from a different computer, Xcode complains about a duplicate interface definition for class 'BFAppLink' (which is from the Bolts framework). This is fixed by "pods update".

Any ideas?


Solution

  • I ran into the same issue with Dropbox and the Parse pod. I investigated and found that CocoaPods keeps symlinks to your headers in ./Pods/Headers for some reasons Dropbox will actually copy the files on the other computer instead of just copying the symlink.

    When you compile on your second computer there's 2 copies of the .h files so Xcode complains and won't compile until you run pod install (which will replace the duplicate .h files with the symlinks like it should). But then your other computers which compiled fine will get their symlinks replaced with duplicates of the header files.

    The way I found around this was to add /Pods/Headers to the selective sync in Dropbox so they won't get sync. Then run pod install on all your computers and they should be able to compile.

    I hope that helped