ruby.taobao.org停止更新使用cocoapods更新rubychina源
May 25, 2021 · View on GitHub
2021 install cocoapods
备注:rbenv安装较慢【等】
brew install rbenv
CFLAGS="-Wno-error=implicit-function-declaration" rvm install 2.6.3
sudo gem install -n /usr/local/bin cocoapods -v 1.10.1
ruby.taobao.org停止更新使用cocoapods更新rubychina源
1. 如何使用?
1.1请尽可能用比较新的 RubyGems 版本,建议 2.6.x 以上。
$ gem update --system # 这里请翻墙一下
$ gem -v
2.6.3
$ gem sources --add https://gems.ruby-china.org/ --remove https://rubygems.org/
$ gem sources -l
https://gems.ruby-china.org
// 确保只有 gems.ruby-china.org
1.2如果你使用 Gemfile 和 Bundle (例如:Rails 项目)
你可以用 Bundler 的 Gem 源代码镜像命令
$ bundle config mirror.https://rubygems.org https://gems.ruby-china.org
这样你不用改你的 Gemfile 的 source
source 'https://rubygems.org/'
gem 'rails', '4.2.5'