zoukankan      html  css  js  c++  java
  • [!] CDN: trunk Repo update failed

    https://www.jianshu.com/p/bf1cbe49cb5d

    由于项目是用CocoaPods管理,CocoaPods 1.8将CDN切换为默认的spec repo源,并附带一些增强功能!CDN支持最初是在1.7版本中引入的,最终在1.7.2中完成。 它旨在大大加快初始设置和依赖性分析。

    目前项目使用pods的是1.8.4版本

    Ribers-Mac:ZNB_Country2.0 Riber$ pod --version 
    1.8.4
    

    最近使用pods,却出现了一下错误!

    [!] CDN: trunk Repo update failed - 17 error(s):
    CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/1/d/4/CocoaAsyncSocket/0.0.1/CocoaAsyncSocket.podspec.json, error: Operation timed out - SSL_connect
    ...
    

    按照官方文档 podfile文件中添加source源:
    source 'https://github.com/CocoaPods/Specs.git'
    podfile文件中添加source源后,pod installpod update可以正常操作,但是pod search有些库却不正常。

    Ribers-Mac:ZNB_Country2.0 Riber$ pod search mj
    [!] CDN: trunk Repo update failed - 3 error(s):
    CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/0.0.1/MJRefresh.podspec.json, error: Operation timed out - SSL_connect
    CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/1.4.4/MJRefresh.podspec.json, error: Operation timed out - SSL_connect
    CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/2.4.9/MJRefresh.podspec.json, error: Operation timed out - SSL_connect
    
    Ribers-Mac:ZNB_Country2.0 Riber$ pod search rbtitle
    -> RBTitleView (2.0.1)
       简单实用的titleView
       pod 'RBTitleView', '~> 2.0.1'
       - Homepage: https://github.com/RiberWang/RBTitleDemo
       - Source:   https://github.com/RiberWang/RBTitleDemo.git
       - Versions: 2.0.1, 1.0.1, 1.0.0 [master repo]
    
    

    解决办法:

    1. podfile文件中指定source源为master:

    source 'https://github.com/CocoaPods/Specs.git'

    2.执行pod repo remove trunk移除trunk源

    执行完后,pod search就都正常了!

    Ribers-Mac:ZNB_Country2.0 Riber$ pod repo list
    
    master
    - Type: git (master)
    - URL:  https://github.com/CocoaPods/Specs.git
    - Path: /Users/Riber/.cocoapods/repos/master
    
    trunk
    - Type: CDN
    - URL:  https://cdn.cocoapods.org/
    - Path: /Users/Riber/.cocoapods/repos/trunk
    
    2 repos
    Ribers-Mac:ZNB_Country2.0 Riber$ pod repo remove trunk
    Removing spec repo `trunk`
    
    注意:podfile文件中一定要指定master源,因为现在默认是trunk

    source 'https://github.com/CocoaPods/Specs.git'

    参考文章:
    1. 官方说明(英语不好的同志可在谷歌浏览器中打开使用其翻译功能)
    2. Github Issules


    作者:RiberWang
    链接:https://www.jianshu.com/p/bf1cbe49cb5d
    来源:简书
    著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。
  • 相关阅读:
    统计学_筛选试验
    ROC、PR 曲线/准确率、覆盖率(召回)、命中率、Specificity(负例的覆盖率)、F1 score
    阳/阴性预测值Positive/negative Predictive Value(推荐AA)
    统计学_样本量估计_python代码实现
    统计学_效应量Effect Size
    统计学_二型错误和功效(Type II Errors and Test Power)
    统计学的P值解释和误区
    【线性代数的几何意义】向量的基本几何意义
    【线性代数的几何意义】什么是线性代数
    【Eclipse】如何在Eclipse中使用命令行?
  • 原文地址:https://www.cnblogs.com/itlover2013/p/13384679.html
Copyright © 2011-2022 走看看