Swift 3.0 xCode 8迁移窗格

时间:2016-09-17 11:36:57

标签: ios swift xcode migration

我在使用xCode 8时遇到了一些问题。

  1. 我已经在swift 3.0 sintax
  2. 中转换了我的.xCodeproject
  3. 我安装了与swift 3.0兼容的所有cocoapod
  4. https://developers.google.com/youtube/iframe_api_reference#Examples

    因此每个pod都需要传统的swift版本或xCode返回ditto错误或者xCode返回有关pods sintax的一些错误。请帮帮我。

2 个答案:

答案 0 :(得分:1)

删除需要将旧版swift版本手动更改为YES任务的pod,将此脚本添加到podfile中。它将通过您的pod并将其设置为使用3.0版本

 post_install do |installer|
   installer.pods_project.targets.each do |target|
     target.build_configurations.each do |configuration|
        configuration.build_settings['SWIFT_VERSION'] = "3.0"
     end
   end
 end

答案 1 :(得分:0)

1.latest xcode 8

2.如果已经在项目中创建了pod文件,那么你可以执行此命令

open -e podfile

然后

    use_frameworks!

    target '<your project name>' do
        pod 'Alamofire', '~> 4.4'
        //your all pod put here above end
    end