更新Pod无效 [英] Updating Pod is not Working
问题描述
我知道此问题之前已被问及我查询了问题答案,但我仍然面临此错误。
[!]无法连接到GitHub以更新CocoaPods / Specs规格
repo - 请检查您是否处于离线状态,或者GitHub是否已关闭
之前一周之前 pod update
命令工作正常,但现在当我运行该命令时,它每次都会给我同样的错误。
我尝试了以下解决方案。
- 我尝试了多个互联网连接的此命令。
2。
pod repo remove master
pod setup
pod install
3。
$ sudo rm -fr~ / .cocoapods / repos / master
$ pod setup
$ pod install
最后我找到了解决方案
5.安装Ruby
由于我想在系统上与Ruby分开安装Ruby,我安装它以便可以切换到rbenv。
$ brew install rbenv ruby-build
$ echo'export PATH =$ HOME / .rbenv / bin:$ PATH'>> 〜/ .bash_profile
$ echo'如果是哪个rbenv>的/ dev / null的;然后评估$(rbenv init - ); fi'>> 〜/ .bash_profile
$ source~ / .bash_profile
6.检查要安装的Ruby版本。
$ rbenv install --list
给出可用版本列表。
安装Ruby。
$ rbenv install 2.1.0
切换版本。
$ rbenv global 2.1.0
7。安装CocoaPods。
$ gem install cocoapods -n / usr / local / bin
如果你想检查pods版本
$ pod --version
确认pod更新正常结束。
$ pod update
I know this question is previously asked and I review that asked question answers but still I am facing this error.
[!] Failed to connect to GitHub to update the CocoaPods/Specs specs repo - Please check if you are offline, or that GitHub is down
Previously before a week ago pod update
command is working fine but now when I run that command it gives me same error everyTime.
I tried below solutions.
- I tried this command with multiple internet connection.
2.
pod repo remove master
pod setup
pod install
3.
$sudo rm -fr ~/.cocoapods/repos/master
$pod setup
$pod install
Finally I found solution from satoshi-iwaki.
This error occurs because
GitHub invalidated vulnerable SSL / TSL on 2018/23.
1. Install (or update) Homebrew.
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" $ brew update
2. Install (or update) OpenSSL.
$ brew install openssl $ brew upgrade openssl
In the log at the time of installation openssl
because the path of the output, in the street PATH
wo .bash_profileso
as to set in.
If you need to have this software first in your PATH run:
echo 'export PATH="/usr/local/opt/openssl/bin:$PATH"' >> ~/.bash_profile
$ source ~/.bash_profile
3. Check the version.
$ which openssl
/usr/local/opt/openssl/bin/openssl
$ openssl version
OpenSSL 1.0.2n 7 Dec 2017
4. Make sure you can access with TLSv 1.2.
$ openssl s_client -connect api.github.com:443
gives log like this.
5.Installing Ruby
Since I want to install Ruby separately from Ruby on the system, I install it so that it can be switched rbenv.
$ brew install rbenv ruby-build $ echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile $ echo 'if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi' >> ~/.bash_profile $ source ~/.bash_profile
6.Check the version of Ruby to install.
$ rbenv install --list
gives list of Available versions.
Install Ruby.
$ rbenv install 2.1.0
Switch the version.
$ rbenv global 2.1.0
7. Install CocoaPods.
$ gem install cocoapods -n /usr/local/bin
If you want to check pods version
$ pod --version
Confirm that pod update ends normally.
$ pod update
这篇关于更新Pod无效的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!