公告
财富商城
积分规则
提问
发文
2020-01-27 14:07发布
The star\"
I'm trying to run downloaded from app, try to open in Xcode and have an error:
" Showing Recent Messages :-1: SWIFT_VERSION '3.0' is unsupported, supported versions are: 4.0, 4.2, 5.0. (in target 'SimpleWeather')"
For Xcode 10.1, select your Pods File
-> Go to Build Settings -> Choose your Pod -> Search "Swift" -> Navigate to "Swift Language version" -> Set to desired language version.
I came across this issue while developing a Cocoapod. I had an old .swift-version file in my repo that specified Swift 3.0.
.swift-version
Running pod lib lint --verbose led me to this helpful response:
pod lib lint --verbose
Please remove the .swift-version file which is now deprecated and only use the swift_version attribute within your podspec.
swift_version
I deleted the file and added spec.swift_version = '5.0' to my podspec file to fix the problem.
spec.swift_version = '5.0'
select pod like as per image and change swift language version this can save you one day
I followed the instructions on this page and the error didn't resolve. Finally, went into
$ vim MyProject.xcodeproj/project.pbxproj
and found two instances where
SWIFT_VERSION = 3.0;
was still being referenced. I changed those to 5.0 and the error was gone. Not sure why those two were still there.
******** Easiest way: **********
1.Click on PODs in the left column.
2.In the centre column select the pod you want, then navigate to "build settings" in the top right panel.
3.Then search "Swift Language Version" and change to a known version.
最多设置5个标签!
For Xcode 10.1, select your Pods File
-> Go to Build Settings -> Choose your Pod -> Search "Swift" -> Navigate to "Swift Language version" -> Set to desired language version.
I came across this issue while developing a Cocoapod. I had an old
.swift-version
file in my repo that specified Swift 3.0.Running
pod lib lint --verbose
led me to this helpful response:I deleted the file and added
spec.swift_version = '5.0'
to my podspec file to fix the problem.select pod like as per image and change swift language version this can save you one day
I followed the instructions on this page and the error didn't resolve. Finally, went into
and found two instances where
was still being referenced. I changed those to 5.0 and the error was gone. Not sure why those two were still there.
******** Easiest way: **********
1.Click on PODs in the left column.
2.In the centre column select the pod you want, then navigate to "build settings" in the top right panel.
3.Then search "Swift Language Version" and change to a known version.