GitCode 开源社区
iOS - 解决Unable to add a source with url `https://github.com/CocoaPods/Specs.git` named
iOS - 解决Unable to add a source with url `https://github.com/CocoaPods/Specs.git` named
[!] Unable to add a source with url `https://github.com/CocoaPods/Specs.git` named `master`.
You can try adding it manually in `~/.cocoapods/repos` or via `pod repo add`.
- 1
- 2
解决方案:
pod repo add master https://github.com/CocoaPods/Specs.git
- 1
然后提示执行’pod setup’,如果出现
[!] The `master` repo is not a git repo.
- 1
进入/users/你的用户名/.cocoapods/repos,删除master文件夹
然后执行
pod setup
如果pod setup 不顺利
采用:Git clone https://git.coding.net/CocoaPods/Specs.git ~/.cocoapods/repos/master 该过程作用与 pod setup作用相同
- 1
如果是安装多个Xcdoe,还需要选择Xcode的路径
sudo xcode-select -switch /Applications/Xcode.app/
- 1
在终端里输入下方命令可以知道Xcode的路径:
xcode-select -p
2: ---------------------------------------------
问题:cocoapods was not able to update the 'master' repo.if it is a unexpected issue and persists you can inspect it running 'pod repo update --verbose'
尝试解决:
尝试1、根据提示,跑一下 pod repo update --verbose
尝试2、如果还是出现原来问题,升级 gem update cocoapods(如果CocoaPods还不是最新版本)
尝试3、如果升级还是出现原来的问题,那么重装CocoaPods 。
首先查看本地装了关于cocoapods的哪些东西,在终端输入gem list --local | grep cocoapods
接着全部卸掉上面的,在终端输入gem uninstall cocoapods
再安装,在终端输入gem install cocoapods
尝试4、如果问题依旧,那么请清除缓存再pod setup
清除命令sudo rm -fr ~/.cocoapods/repos/master
再pod setup
3 安装 pod 报错--------------------------------
ERROR: While executing gem ... (OpenSSL::SSL::SSLError)
方法一:
1) outdate open SSL
$ rvm -v
$ rvm get head
2) outdate bundle
$ gem install bundle
方法二:
$ gem update --system
方法三:
$ apt-get install openssl
更多推荐
- 4.4w
- 4
- 0
- 0
扫一扫分享内容
- 分享
已为社区贡献1条内容
回到
顶部
顶部
所有评论(0)