CocoaPods镜像源 解决RN项目初始下载崩的问题

2020-11-04  本文已影响0人  AizawaSayo

新版的 CocoaPods 已经不允许用pod repo add直接添加master库了,但是依然可以:
1. 先移除

cd ~/.cocoapods/repos 
pod repo remove master

2. 再更换:
(1) 码云(持续更新,每日同步一次)
亲测好用,目前用的是这个,其他备用

git clone https://gitee.com/mirrors/CocoaPods-Specs.git master

(2) 腾讯云(也蛮快的)

git clone https://mirrors.cloud.tencent.com/CocoaPods/Specs.git

(3) 清华大学源

git clone https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git master

(4) 北京外国语大学

git clone https://mirrors.bfsu.edu.cn/git/CocoaPods/Specs.git master

(5) gitclub

git clone https://gitclub.cn/CocoaPods/Specs.git master

3. 最后进入自己的工程,在自己工程的podFile第一行加上:

source 'https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git'
上一篇下一篇

猜你喜欢

热点阅读