iosswiftmigrationxcode10.1xcode11.4

How can change Swift 3 to 4 in Xcode 11.4


Current I am using Xcode11.4. I need to use Xcode 11.4 for iOS 13 frameworks but I cant build my old project in Xcode 11 Here is the error message

This workplace has projects that contain source code developed with Swift 3.x.This version of Xcode does not support building or migrating Swift 3.x targets
Use Xcode 10.1 to migrate the code to Swift 4

I tried to change Swift Language version to Swift 4 in all Pods . enter image description here

But Some of the Pods is showing error like that

Error

How Can I fixed that error,Does I need to install Xcode 10.1 again?


Solution

  • There are 2 ways you can do the migration

    1. Use Xcode 10.1's migration tool to update your code-base directly to swift4 But this will still require manual pod update

    2. If your code-base is small, you can skip the hassle of downloading and installing of Xcode and could manually update code to swift 4 by refactoring.

    Follow this tutorial, It is comprehensive enough for migration