安装Pod库
2020-10-13 本文已影响0人
大熊Daniel
最新版的MacOS Catalina系统命令行执行pod setup 会造成命令直接结束
1.先清空以下文件夹
/Users/username/.cocoapods/repos/trunk
2.执行
git clone https://github.com/CocoaPods/Specs.git ~/.cocoapods/repos/trunk
或者
git clone https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git ~/.cocoapods/repos/trunk
或者
git clone https://github.com/CocoaPods/Specs.git ~/.cocoapods/repos/trunk --depth 1
git clone https://github.com/CocoaPods/Specs.git master --depth 1
git clone --depth=1 https://github.com/CocoaPods/Specs.git master
git clone git://github.com/CocoaPods/Specs.git ~/.cocoapods/repos/trunk
3.正确的目录结构
image.png
4.验证
pod search AFNetworking