Failed to connect to GitHub to update the CocoaPods/Specs specs repo

2,193 阅读1分钟

今天拉取工程代码,pod install 之后报了如下错误:

2c6b24bc5950c6dbb6739b5b3f7a633e

所以看了下 Podfile 文件,发现一直依赖的 SDWebImage 升级到了最新版本:

pod 'SDWebImage', '5.9.0'

很自然的,我也需要升级本地的该库,但试了多种方式,就是不行,最终定位在了这条错误提示:

image-20200904142706375

[!] Failed to connect to GitHub to update the CocoaPods/Specs specs repo - Please check if you are offline, or that GitHub is down

无奈我都准备重装 CocoaPods 了,最后抱着试一试的想法,更新了一下 CocoaPods 工程,还真的好了,具体操作如下:

cd ~/.cocoapods/repos/cocoapods
git pull

待 CocoaPods 完成更新,再更新工程就可以了:

image-20200904143629998