tristanhimmelman/AlamofireObjectMapper

Swift 4 support

Closed this issue ยท 18 comments

Do you have a branch for Swift 4 and Xcode 9?

Same. Would love an update for Swift 4.

+1

+1

GerdC commented

+1

+1

I've just quickly created a swift-4 branch. Everything seems to be working as expected. Let me know if you have issues.

+1

I changed the AlamofireObjectMapper dependency to swift4 branch, clean the project and build it but there were some problem yet with ObjectMapper in file IntegerOperators.swift related to Swift 4 migration. I had to edit it and works fine, thanks!

To point to swift4's branch using Pod:

pod 'AlamofireObjectMapper', :git ='https://github.com/tristanhimmelman/AlamofireObjectMapper.git', :branch => 'swift-4'

@tristanhimmelman I use AlamofireObjectMapper as a core dependency in one of my own pods which means pointing to a particular git repo and branch won't work. Any chance you can release a Swift 4 release? ๐Ÿ˜„

The swift4 branch is almost ready to merge into master however I'm seeing a few travis build issues that seem related to release builds. If anybody has the time to test the branch and see if release builds are working within your project that would be much appreciated.

@tristanhimmelman thanks for the update. I would test if I could but unfortunately, podspecs don't allow you to point to a separate branch. They require you to target a specific tagged release.

Actually you can. See this from CocoaPods documentation:
pod 'Alamofire', :git => 'https://github.com/Alamofire/Alamofire.git', :branch => 'dev'

@tristanhimmelman If this were my Podfile, then yes I could. But a podspec and a podfile are two completely different things. See here

My bad, I misread your comment.

@tristanhimmelman No problem ๐Ÿ˜„ I'm not in a huge rush right now, but it would nice by the end of the year to eventually convert everything over. I'll patiently wait until then. ๐Ÿ‘

The swift 4 version has now been released!

@tristanhimmelman awesome, thanks a bunch! ๐Ÿ‘