With the upcoming release of Swift 3 (and the newly introduced incompatibility to Swift 2.2 and older in Xcode 8) it would be great to have a separate branch with Swift 3 compatibility.
Please consider also adding a Swift 2.3 branch for people who can鈥檛 migrate to Swift 3, because of other dependencies.
Tried branch Swift3 but xcode still wants to convert it and it has 702 errors like:

Yes, there鈥檚 already a branch with the right naming for Swift 3, but the version isn鈥檛 ready for Swift 3 yet. There are some pull requests that add Swift 3 compatibility, but they aren鈥檛 merged in. Using forks / manually merging in pull requests will be problematic in ongoing projects that also depend on a package manager like CocoaPods or Carthage.
Is there any ETA for Swift 3 compatibility (at least in form of untested beta code)?
I use the swift3 branch of acegreen's fork
Now that Swift3 is GM, you should merge everything into master and make a 3.0 release. Older projects can pin their Carthage/Cocoapod work at the previous version 2.3.1 and security issues and bugs can be backported to 2.3.x releases.
@adamn I would also like to see a Swift 2.3 option rebased on top of whatever is the latest Swift 2 release.
@danielphillips I think the idea is that master would be 3.x and there would be a maintenance branch for 2.3.x that only includes ports of bugfixes and security issues. But I'm not the maintainer so it's only a suggestion.
Having a nightmare to upgrade to Swift 3. Can anyone point me how can I point my cocoapods to acegreen's swift3 fork ?
@gloffreda you need to add the link after the pod name if its a custom location
pod 'SwiftyJSON', :git => 'https://github.com/nameOfUserHere/SwiftyJSON.git'
the info is here http://guides.cocoapods.org/using/the-podfile.html
and if its a specific branch its this
pod 'Alamofire', :git => 'https://github.com/Alamofire/Alamofire.git', :branch => 'dev'
Yes I did it but it gets the master. Found the solution:
pod 'SwiftyJSON', :git => 'https://github.com/acegreen/SwiftyJSON.git', :branch => 'swift3'
Thank you and hope it helps others
This solution doesn't work if your project which is also a cocoapod depends on another cocoapod.
In a pod spec file, you cannot define custom branches, or repos for a pod, only a version number of a published pod. Obviously the above works with an Xcode projects Podfile, but it does not work in a pod spec file.
# -------------------------------------------
# s.dependency 'Alamofire', '~> 4.0'
> s.dependency 'SwiftyJSON', :git => 'https://github.com/acegreen/SwiftyJSON.git', :branch => 'swift3'
# s.dependency 'SwiftyUserDefaults', '~> 3.0'
# -------------------------------------------
So the sooner we can merge into master and put out a new release the better for us who depends on this!
@kylebrowning I don鈥檛 know your project structure in detail, but I had a similar issue like you. In my case I removed the explicit reference to the branch in the spec, and instead made sure that I reference it in the (enclosing) Podfile. This way my custom pod that depended on another pod where I needed to specify a branch just took the right branch, because the Podfile fetched it into the Pods directory.
@rbugajewski Yeah that works if im building the project myself, but im providing a library that depends on SwiftyJSON. So I cannot provide the git or branch in a pod spec file, only a podfile, which is end user specific.
People download my pod via their own podfile so the only way for them to get this is for me to have a step two which is add this other line to your podfile. While annoying, its not undoable, but its making me rethink my use of SwitfyJSON and dependencies in general. IN the case of this one being abandoned, I will definitely move off.
@kylebrowning Yep, I鈥檓 sorry and I understand your dilemma. I鈥檓 also considering removing SwiftyJSON from my dependencies as it is just a small wrapper around the already really easy to use Apple framework classes that in my opinion feel _swiftier_ (for the protocol: I said this 馃挬 for the first time) with Swift 3 than this wrapper.
Same as you @rbugajewski I decided to remove SwiftyJSON as it is now easy to work without it with swift3. I would have kept it if it was updated but now that I am updating my projects to swift 3 I don't have many choices.
Swift3 and Swift2.3 support is here
Closing this one to cleanup the issue list, feel free to reopen this if needed.
Cheers
I would love love love love love love love love love love if this was swift 3 compatible!!!!
@jack-lynch Swift 3 compatible is already there. See #647
Most helpful comment
Now that Swift3 is GM, you should merge everything into master and make a 3.0 release. Older projects can pin their Carthage/Cocoapod work at the previous version 2.3.1 and security issues and bugs can be backported to 2.3.x releases.