整合新的 Firebase .. 错误 cocoapods

intergating New Firebase.. error cocoapods

当我放入 pod 'Firebase' 时,我没有在其中获取 Analytics,它说的是版本 2.5.1,当我说 pod 'Firebase/Analytics'

Unable to satisfy the following requirements:

- `Firebase/Analytics` required by `Podfile`

None of your spec sources contain a spec satisfying the dependency: `Firebase/Analytics`.

You have either:
 * out-of-date source repos which you can update with `pod repo update`.
 * mistyped the name or version.
 * not added the source repo that hosts the Podspec to your Podfile.

Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.

当我执行 pod update Firebase 时,它​​在

处停留了几个小时
Performing a deep fetch of the `master` specs repo to improve future performance

我已经尝试了所有方法我已经更新了我所有的 cocoapods 版本..我不知道是什么问题..

Podfile 代码

# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'

target 'NewFirebase' do
  # Comment this line if you're not using Swift and don't want to use dynamic frameworks
  use_frameworks!


  pod 'Firebase’
  pod 'Firebase/Analytics’


  target 'NewFirebaseTests' do
    inherit! :search_paths
    # Pods for testing
  end

  target 'NewFirebaseUITests' do
    inherit! :search_paths
    # Pods for testing
  end

end

谢谢 雅利安人

这里建立的:

https://firebase.google.com/docs/ios/setup#add_firebase_to_your_app

Firebase 分析包含在 Firebase/Core 中,这实际上是

中唯一包含的东西
pod 'Firebase'

所以你不需要添加 pod 'Firebase/Analytics' ,它不存在

您可能需要通过 运行 pod repo update (Source Link).

同步您的 Cocoapods 主存储库

当我的同步失败时,快速重新安装 Cocoapods 修复了同步错误。