Homebrew 遇到 Failed to connect to api.github.com port 443
jason@Jason software % brew search cmake
Warning: Error searching on GitHub: curl failed! % Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (7) Failed to connect to api.github.com port 443: Connection refused
打开 IP地址查询,将上面的域名 api.github.com
复制进去搜索,将结果中的 IP Address 的地址和域名,添加到 /etc/hosts
文件中
Domain github.com
IP Address 140.82.114.5
Web Server Location United States
jason@Jason software % brew search cmake
==> Formulae
cmake kde-extra-cmake-modules
==> Casks
cmake